DeleteObject() can fail if the object is a DC, however we've already

called GDI_ReleaseObj() so don't call it again.
This commit is contained in:
Huw D M Davies 2002-08-15 23:19:40 +00:00 committed by Alexandre Julliard
parent 66e3183099
commit 6b5aaa1162

View file

@ -877,10 +877,8 @@ BOOL WINAPI DeleteObject( HGDIOBJ obj )
/* Delete object */
if (header->funcs &&
header->funcs->pDeleteObject &&
header->funcs->pDeleteObject( obj, header ))
return TRUE;
if (header->funcs && header->funcs->pDeleteObject)
return header->funcs->pDeleteObject( obj, header );
GDI_ReleaseObj( obj );
return FALSE;