[Python-checkins] python/dist/src/Modules socketmodule.c,1.241,1.242
gvanrossum@users.sourceforge.net
gvanrossum@users.sourceforge.net
Thu, 08 Aug 2002 13:39:34 -0700
Update of /cvsroot/python/python/dist/src/Modules
In directory usw-pr-cvs1:/tmp/cvs-serv14007
Modified Files:
socketmodule.c
Log Message:
The other half of the patches added to SF patch 555085 by A I
MacIntyre. At least on OS/2, a subsequent connect() on a nonblocking
socket returns errno==EISCONN to indicate success. This seems
harmless on Unix.
Index: socketmodule.c
===================================================================
RCS file: /cvsroot/python/python/dist/src/Modules/socketmodule.c,v
retrieving revision 1.241
retrieving revision 1.242
diff -C2 -d -r1.241 -r1.242
*** socketmodule.c 8 Aug 2002 20:37:08 -0000 1.241
--- socketmodule.c 8 Aug 2002 20:39:30 -0000 1.242
***************
*** 1328,1331 ****
--- 1328,1333 ----
internal_select(s, 1);
res = connect(s->sock_fd, addr, addrlen);
+ if (res < 0 && errno == EISCONN)
+ res = 0;
}
}