Browse Source

* fix INVALID_SOCKET for other platforms too

git-svn-id: trunk@7329 -
Almindor 18 years ago
parent
commit
f83568d897
4 changed files with 13 additions and 1 deletions
  1. 3 1
      rtl/freebsd/unxsockh.inc
  2. 4 0
      rtl/netware/netwsockh.inc
  3. 3 0
      rtl/netwlibc/netwsockh.inc
  4. 3 0
      rtl/os2/sockets.pas

+ 3 - 1
rtl/freebsd/unxsockh.inc

@@ -346,4 +346,6 @@ Const
   MSG_COMPAT    = $8000;
   MSG_SOCALLBCK = $10000;
   MSG_NOSIGNAL  = $20000;              { Do not generate SIGPIPE }
-
+  
+  INVALID_SOCKET = -1;
+  SOCKET_ERROR = -1;

+ 4 - 0
rtl/netware/netwsockh.inc

@@ -52,3 +52,7 @@ const
        PF_ATM = AF_ATM;
        PF_INET6 = AF_INET6;
        PF_MAX = AF_MAX;
+       
+  INVALID_SOCKET = -1;
+  SOCKET_ERROR = -1;
+

+ 3 - 0
rtl/netwlibc/netwsockh.inc

@@ -52,3 +52,6 @@ const
        PF_ATM = AF_ATM;
        PF_INET6 = AF_INET6;
        PF_MAX = AF_MAX;
+       
+  INVALID_SOCKET = -1;
+  SOCKET_ERROR = -1;

+ 3 - 0
rtl/os2/sockets.pas

@@ -124,6 +124,9 @@ Type
 // OS/2 stack based on BSD stack
 {$DEFINE BSD}
 {$I socketsh.inc}
+  INVALID_SOCKET = TSocket(not(0));
+  SOCKET_ERROR = -1;
+
 
 Implementation