mirror of
https://github.com/FunkyFr3sh/cnc-ddraw.git
synced 2025-03-24 17:49:52 +01:00
Fix a recursive call when DirectDraw is created more than once
This commit is contained in:
parent
88bac67fd5
commit
17968c433c
2
main.c
2
main.c
@ -370,6 +370,8 @@ ULONG __stdcall ddraw_Release(IDirectDrawImpl *This)
|
|||||||
|
|
||||||
if(This->Ref == 0)
|
if(This->Ref == 0)
|
||||||
{
|
{
|
||||||
|
/* restore old wndproc, subsequent ddraw creation will otherwise fail */
|
||||||
|
SetWindowLong(This->hWnd, GWL_WNDPROC, (LONG)This->WndProc);
|
||||||
//free(This);
|
//free(This);
|
||||||
ddraw = NULL;
|
ddraw = NULL;
|
||||||
return 0;
|
return 0;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user