Commit b60ff098 authored by Alexandre Julliard's avatar Alexandre Julliard

Avoid recursive DeleteDC calls.

parent 1bb69a0c
...@@ -770,8 +770,11 @@ BOOL WINAPI DeleteDC( HDC hdc ) ...@@ -770,8 +770,11 @@ BOOL WINAPI DeleteDC( HDC hdc )
if (!(dcs = GDI_GetObjPtr( hdcs, DC_MAGIC ))) break; if (!(dcs = GDI_GetObjPtr( hdcs, DC_MAGIC ))) break;
dc->header.hNext = dcs->header.hNext; dc->header.hNext = dcs->header.hNext;
dc->saveLevel--; dc->saveLevel--;
GDI_ReleaseObj( hdcs ); if (dcs->hClipRgn) DeleteObject( dcs->hClipRgn );
DeleteDC( hdcs ); if (dcs->hVisRgn) DeleteObject( dcs->hVisRgn );
if (dcs->hGCClipRgn) DeleteObject( dcs->hGCClipRgn );
PATH_DestroyGdiPath(&dcs->path);
GDI_FreeObject( hdcs, dcs );
} }
if (!(dc->flags & DC_SAVED)) if (!(dc->flags & DC_SAVED))
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment