--- a/Unix.st Mon Jul 03 04:38:27 1995 +0200
+++ b/Unix.st Sat Jul 22 21:25:26 1995 +0200
@@ -22,7 +22,7 @@
COPYRIGHT (c) 1988 by Claus Gittinger
All Rights Reserved
-$Header: /cvs/stx/stx/libbasic/Attic/Unix.st,v 1.39 1995-06-27 02:14:58 claus Exp $
+$Header: /cvs/stx/stx/libbasic/Attic/Unix.st,v 1.40 1995-07-22 19:25:09 claus Exp $
'!
!OperatingSystem primitiveDefinitions!
@@ -122,8 +122,6 @@
#endif /* ! transputer */
-extern int __immediateInterrupt__;
-
/*
* on some systems errno is a macro ... check for it here
*/
@@ -161,7 +159,7 @@
version
"
-$Header: /cvs/stx/stx/libbasic/Attic/Unix.st,v 1.39 1995-06-27 02:14:58 claus Exp $
+$Header: /cvs/stx/stx/libbasic/Attic/Unix.st,v 1.40 1995-07-22 19:25:09 claus Exp $
"
!
@@ -1148,6 +1146,57 @@
msg = "Connection refused";
break;
#endif
+#ifdef ENETDOWN
+ case ENETDOWN:
+ msg = "Network is down";
+ break;
+#endif
+#ifdef ENETUNREACH
+ case ENETUNREACH:
+ msg = "Network is unreachable";
+ break;
+#endif
+#ifdef ENETRESET
+ case ENETRESET:
+ msg = "Network dropped conn due to reset";
+ break;
+#endif
+#ifdef ECONNABORTED
+ case ECONNABORTED:
+ msg = "Software caused connection abort";
+ break;
+#endif
+#ifdef ECONNRESET
+ case ECONNRESET:
+ msg = "Connection reset by peer";
+ break;
+#endif
+#ifdef EISCONN
+ case EISCONN:
+ msg = "Socket is already connected";
+ break;
+#endif
+#ifdef ENOTCONN
+ case ENOTCONN:
+ msg = "Socket is not connected";
+ break;
+#endif
+#ifdef ESHUTDOWN
+ case ESHUTDOWN:
+ msg = "Can't send after socket shutdown";
+ break;
+#endif
+#ifdef EHOSTDOWN
+ case EHOSTDOWN:
+ msg = "Host is down";
+ break;
+#endif
+#ifdef EHOSTUNREACH
+ case EHOSTUNREACH:
+ msg = "No route to host";
+ break;
+#endif
+
default:
sprintf(buffer, "ErrorNr: %d", _intVal(errNr));
msg = buffer;
@@ -2858,12 +2907,12 @@
/*
* make certain, that interrupt gets us out of the select
*/
- __immediateInterrupt__ = 1;
+ __BEGIN_INTERRUPTABLE__
errno = 0;
do {
ret = select(maxF+1, &rset, &wset, &eset, &wt);
} while (0 /* (ret < 0) && (errno == EINTR) */ );
- __immediateInterrupt__ = 0;
+ __END_INTERRUPTABLE__
if (ret > 0) {
for (i=0; i <= maxF; i++) {