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

Issue 11293036: Free the dibsection (HBITMAP) in PlatformBitmap's destructor, so we don't leak! (Closed)

Created:
8 years, 1 month ago by reed1
Modified:
8 years, 1 month ago
Reviewers:
bungeman-skia
CC:
chromium-reviews, mal, dharani, tonyg_google
Visibility:
Public.

Description

Free the dibsection (HBITMAP) in PlatformBitmap's destructor, so we don't leak! This adds an extra slot to PlatformBitmap, which is implemented for all platforms. To do this simply, an intptr_t field is added (platform_extra_) which is initialized to 0. At the moment, only the windows port uses this, but there is no cost to the other ports. BUG=158931 Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=165424

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+9 lines, -2 lines) Patch
M skia/ext/bitmap_platform_device_win.cc View 2 chunks +6 lines, -0 lines 0 comments Download
M skia/ext/platform_canvas.h View 1 chunk +2 lines, -1 line 0 comments Download
M skia/ext/platform_canvas.cc View 1 chunk +1 line, -1 line 0 comments Download

Messages

Total messages: 2 (0 generated)
reed1
8 years, 1 month ago (2012-11-01 15:21:03 UTC) #1
bungeman-skia
8 years, 1 month ago (2012-11-01 16:52:06 UTC) #2
LGTM

I find assigning the handle to an intptr_t to be somewhat strange, but it looks
as though the Windows headers are stuck allowing that to work.

Powered by Google App Engine
This is Rietveld 408576698