Parcourir la source

BSocket: assert that BSocket_GlobalInit has been called

ambrop7 il y a 15 ans
Parent
commit
8edc4af402
1 fichiers modifiés avec 2 ajouts et 1 suppressions
  1. 2 1
      system/BSocket.c

+ 2 - 1
system/BSocket.c

@@ -639,9 +639,10 @@ fail0:
     return -1;
     return -1;
 }
 }
 
 
+// NOTE: if you change something here, you might also have to change BSocket_Accept
 int BSocket_Init (BSocket *bs, BReactor *bsys, int domain, int type)
 int BSocket_Init (BSocket *bs, BReactor *bsys, int domain, int type)
 {
 {
-    // NOTE: if you change something here, you might also have to change BSocket_Accept
+    ASSERT(bsocket_initialized)
     
     
     // translate domain
     // translate domain
     int sys_domain;
     int sys_domain;