gdi32: Fix possible NULL pointer dereference (Coverity).

oldstable
Paul Vriens 2007-08-22 08:32:47 +02:00 committed by Alexandre Julliard
parent 1ee9ea91a5
commit 4b098028f3
1 changed files with 5 additions and 2 deletions

View File

@ -1617,8 +1617,11 @@ INT WINAPI GetRelAbs( HDC hdc, DWORD dwIgnore )
{
INT ret = 0;
DC *dc = DC_GetDCPtr( hdc );
if (dc) ret = dc->relAbsMode;
DC_ReleaseDCPtr( dc );
if (dc)
{
ret = dc->relAbsMode;
DC_ReleaseDCPtr( dc );
}
return ret;
}