]> git.saurik.com Git - wxWidgets.git/blobdiff - src/gtk1/gsockgtk.c
The world should not end if a server has no peer. Let's return FALSE instead.
[wxWidgets.git] / src / gtk1 / gsockgtk.c
index 3202c6b42139cfae3f9a269aef5b5db625938997..fc88b47ddbbc27f72a8e704428cf6c9df013fbbc 100644 (file)
@@ -9,6 +9,7 @@
 
 #if wxUSE_SOCKETS
 
+#include <assert.h>
 #include <stdlib.h>
 #include <stdio.h>
 
@@ -80,6 +81,8 @@ void _GSocket_Uninstall_Callback(GSocket *socket, GSocketEvent event)
   gint *m_id = (gint *)(socket->m_gui_dependent);
   int c;
 
+  assert( m_id != NULL );
+
   switch (event)
   {
     case GSOCK_LOST:       /* fall-through */