DO NOT top post bottom posted emails!!! Nick Burns wrote: >> From: Stefan Dösinger <[EMAIL PROTECTED]> >> To: wine-devel@winehq.org >> CC: Nick Burns <[EMAIL PROTECTED]> >> Subject: Re: dlls/opengl32/wgl.c: minor dealloc fix >> Date: Mon, 1 Jan 2007 22:33:49 +0100 >> >> >> Am 01.01.2007 um 11:03 schrieb Nick Burns: >> >>> There can be a problem where the detach is hit before >>> internal_gl_extensions is allocated and it tries to free NULL and >>> dies... >>> >>> This just checks for the allocation before freeing -- very minor >>> >>> - Nick >> HeapFree(GetProcessHeap(), 0, NULL) is supposed to be a nop, so the >> check is not needed. > According to... > http://msdn2.microsoft.com/en-us/library/aa366701.aspx > > lpMem > [in] ...If this pointer is NULL, the behavior is undefined.
That's incorrect. 90% of MSDN is not correct or incomplete. The behavior is well known and defined (at least in Wine) - NULL pointers are ignored. So your patch is not correct. Vitaliy.