[PATCH 08/10] gdi32: Where possible directly access the DC instead of using GetCurrentObject().
Alexandre Julliard
julliard at winehq.org
Fri Jul 29 09:32:34 CDT 2016
Huw Davies <huw at codeweavers.com> writes:
> On Fri, Jul 29, 2016 at 09:22:43PM +0900, Alexandre Julliard wrote:
>> Huw Davies <huw at codeweavers.com> writes:
>>
>> > @@ -1039,7 +1039,7 @@ INT WINAPI SetGraphicsMode( HDC hdc, INT mode )
>> > }
>> > release_dc_ptr( dc );
>> > /* font metrics depend on the graphics mode */
>> > - if (ret) SelectObject(dc->hSelf, GetCurrentObject(dc->hSelf, OBJ_FONT));
>> > + if (ret) SelectObject(dc->hSelf, dc->hFont);
>>
>> The bug was already present, but we shouldn't be accessing the dc after
>> release.
>
> Good catch (although it was originally your bug ;-) )
Then it can't be a bug. There are no bugs in my code.
--
Alexandre Julliard
julliard at winehq.org
More information about the wine-devel
mailing list