Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(3)

Issue 14617019: Fix memory leak in SkTypeface.cpp (Closed)

Created:
7 years, 7 months ago by robertphillips
Modified:
7 years, 7 months ago
Reviewers:
bungeman, reed1
CC:
skia-review_googlegroups.com
Visibility:
Public.

Description

This fixes this leak: ==21532== 1,825,936 (1,779,668 direct, 46,268 indirect) bytes in 35 blocks are definitely lost in loss record 86 of 86 ==21532== at 0x4C2B6CD: malloc (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so) ==21532== by 0x541C5C: sk_malloc_flags(unsigned long, unsigned int) (SkMemory_malloc.cpp:44) ==21532== by 0x4A0D90: SkTypeface::Deserialize(SkStream*) (SkTypeface.cpp:117) ==21532== by 0x46FEB0: SkPicturePlayback::parseStreamTag(SkStream*, SkPictInfo const&, unsigned int, unsigned long, bool (*)(void const*, unsigned long, SkBitmap*)) (SkPicturePlayback.cpp:511) ==21532== by 0x47059A: SkPicturePlayback::SkPicturePlayback(SkStream*, SkPictInfo const&, bool (*)(void const*, unsigned long, SkBitmap*)) (SkPicturePlayback.cpp:603) ==21532== by 0x46CA7D: SkPicture::initFromStream(SkStream*, bool*, bool (*)(void const*, unsigned long, SkBitmap*)) (SkPicture.cpp:293) ==21532== by 0x46C991: SkPicture::SkPicture(SkStream*, bool*, bool (*)(void const*, unsigned long, SkBitmap*)) (SkPicture.cpp:272) ==21532== by 0x4077D4: filter_picture(SkString const&, SkString const&) (filtermain.cpp:633) ==21532== by 0x408084: tool_main(int, char**) (filtermain.cpp:790) ==21532== by 0x408237: main (filtermain.cpp:810)

Patch Set 1 #

Total comments: 1
Unified diffs Side-by-side diffs Delta from patch set Stats (+3 lines, -2 lines) Patch
M src/core/SkTypeface.cpp View 1 chunk +3 lines, -2 lines 1 comment Download

Messages

Total messages: 3 (0 generated)
robertphillips
7 years, 7 months ago (2013-05-10 16:53:43 UTC) #1
reed1
lgtm https://codereview.chromium.org/14617019/diff/1/src/core/SkTypeface.cpp File src/core/SkTypeface.cpp (right): https://codereview.chromium.org/14617019/diff/1/src/core/SkTypeface.cpp#newcode119 src/core/SkTypeface.cpp:119: SkAutoTUnref<SkMemoryStream> localStream(SkNEW(SkMemoryStream)); Grrr, we should look for a ...
7 years, 7 months ago (2013-05-10 16:58:09 UTC) #2
robertphillips
7 years, 7 months ago (2013-05-10 17:23:07 UTC) #3
Message was sent while issue was closed.
committed as r9099

Powered by Google App Engine
This is Rietveld 408576698