Socket.st
changeset 2818 94d67df5c00d
parent 2773 ab3049f4a351
child 2823 10179ccfae5d
--- a/Socket.st	Mon Sep 03 21:58:34 2012 +0200
+++ b/Socket.st	Mon Sep 03 22:23:42 2012 +0200
@@ -28,10 +28,16 @@
 
 #ifdef WIN32
 
+/* this is to catch uses of those - there should be none */
 # undef __BEGIN_INTERRUPTABLE__
 # undef __END_INTERRUPTABLE__
-# define __BEGIN_INTERRUPTABLE__ ..
-# define __END_INTERRUPTABLE__ ..
+# ifdef __TCC__
+#  define __BEGIN_INTERRUPTABLE__ xxxx
+#  define __END_INTERRUPTABLE__ yyyy
+# else
+#  define __BEGIN_INTERRUPTABLE__ ..
+#  define __END_INTERRUPTABLE__ ..
+# endif
 
 # define WRAP_STDIO
 # define SET_LINGER_WHEN_CREATING_SOCKET
@@ -68,7 +74,7 @@
 #include <errno.h>
 
 #ifdef WIN32
-# ifndef __VISUALC__
+# ifdef __BORLANDC__
 #  include <Ws2tcpip.h>
 # endif
 #else
@@ -2995,6 +3001,7 @@
     ].
 
 %{  /* STACK: 32000 */
+#ifndef NO_SOCKET
     OBJ fp = __INST(handle);
 
     if (fp != nil) {
@@ -3206,7 +3213,7 @@
 	ok = ( setsockopt( sock, level, opt, &u, usize) >= 0) ? true : false;
     }
 argError: ;
-
+#endif /* NO_SOCKET */
 %}.
     ok isNil ifTrue:[
 	self primitiveFailed
@@ -4010,9 +4017,9 @@
 !Socket class methodsFor:'documentation'!
 
 version
-    ^ '$Header: /cvs/stx/stx/libbasic2/Socket.st,v 1.268 2012-08-05 16:19:07 cg Exp $'
+    ^ '$Header: /cvs/stx/stx/libbasic2/Socket.st,v 1.269 2012-09-03 20:23:42 cg Exp $'
 !
 
 version_CVS
-    ^ '$Header: /cvs/stx/stx/libbasic2/Socket.st,v 1.268 2012-08-05 16:19:07 cg Exp $'
+    ^ '$Header: /cvs/stx/stx/libbasic2/Socket.st,v 1.269 2012-09-03 20:23:42 cg Exp $'
 ! !