WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
27031
[WINCE] needs OwnPtr<HDC>
https://bugs.webkit.org/show_bug.cgi?id=27031
Summary
[WINCE] needs OwnPtr<HDC>
Joe Mason
Reported
2009-07-07 08:20:47 PDT
Our WinCE port stores HDC's in an OwnPtr, so we added a deleteOwnedPtr override for HDC. I've enabled this for all Windows builds, because it seems useful for all of them and will optimize out if it's not used. I could easily change the patch to define it for WINCE only if that's preferred. Yong points out that only HDC's created with CreateCompatibleDC can be stored in an OwnPtr - those returned by GetDC would be double-deleted. I don't think this is dangerous because it's the same situation with any resource that's deleted by someone else: you don't own HDC's returned by GetDC, so you shouldn't put them in an OwnPtr.
Attachments
patch implemented deleteOwnedPtr(HDC) for Windows
(2.25 KB, patch)
2009-07-07 08:39 PDT
,
Joe Mason
staikos
: review+
Details
Formatted Diff
Diff
View All
Add attachment
proposed patch, testcase, etc.
Joe Mason
Comment 1
2009-07-07 08:39:11 PDT
Created
attachment 32380
[details]
patch implemented deleteOwnedPtr(HDC) for Windows
David Kilzer (:ddkilzer)
Comment 2
2009-07-09 13:00:16 PDT
Committing to
http://svn.webkit.org/repository/webkit/trunk
... M JavaScriptCore/ChangeLog M JavaScriptCore/wtf/OwnPtrCommon.h M JavaScriptCore/wtf/OwnPtrWin.cpp Committed
r45669
M JavaScriptCore/wtf/OwnPtrWin.cpp M JavaScriptCore/wtf/OwnPtrCommon.h M JavaScriptCore/ChangeLog
r45669
= fdd939e9c7043d4f6e1b9643a262aaf50a7ec2af (trunk) No changes between current HEAD and refs/remotes/trunk Resetting to the latest refs/remotes/trunk
http://trac.webkit.org/changeset/45669
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug