don't crash when destroying a not initialized socket (patch 1489095)

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@39404 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin
2006-05-28 23:38:11 +00:00
parent 347f5baaa1
commit b5b0a35d6b

View File

@@ -335,6 +335,7 @@ void GSocketGUIFunctionsTableConcrete::Destroy_Socket(GSocket *socket)
{
/* Remove the socket from the list */
EnterCriticalSection(&critical);
if ( socket->IsOk() )
socketList[(socket->m_msgnumber - WM_USER)] = NULL;
LeaveCriticalSection(&critical);
}