|
From: John M M. <jo...@us...> - 2003-12-16 22:09:33
|
Update of /cvsroot/squeak/squeak/platforms/Mac OS/plugins/SocketPlugin
In directory sc8-pr-cvs1:/tmp/cvs-serv16421/squeak/platforms/Mac OS/plugins/SocketPlugin
Modified Files:
sqMacNetwork.c
Log Message:
3.7.0b3 Add logic to deal with binding to a specific interface in os-9.x, requires a change set to add the primitive call.
Index: sqMacNetwork.c
===================================================================
RCS file: /cvsroot/squeak/squeak/platforms/Mac OS/plugins/SocketPlugin/sqMacNetwork.c,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -d -r1.5 -r1.6
*** sqMacNetwork.c 20 Jun 2003 01:46:26 -0000 1.5
--- sqMacNetwork.c 16 Dec 2003 22:09:30 -0000 1.6
***************
*** 64,67 ****
--- 64,68 ----
v1.3.13 Sept 2002, JMM fixes for wildcard port binding, and IP_ADD_MEMBERSHIP logic
v1.4.00 Feb 2003, JMM watch out for async port fetch info not working under os-x
+ V1.5.00 Dec 2003, JMM add sqSocketListenOnPortBacklogSizeInterface logic
Notes beware semaphore's lurk for socket support. Three semaphores lives in Smalltalk, waiting for
***************
*** 778,783 ****
}
-
void sqSocketListenOnPortBacklogSize(SocketPtr s, int port, int backlogSize) {
EPInfo* epi;
SInt32 sema,readSema,writeSema;
--- 779,788 ----
}
void sqSocketListenOnPortBacklogSize(SocketPtr s, int port, int backlogSize) {
+ sqSocketListenOnPortBacklogSizeInterface(s, port, backlogSize, 0);
+ }
+
+ void sqSocketListenOnPortBacklogSizeInterface(SocketPtr s, int port, int backlogSize, int addr) {
+
EPInfo* epi;
SInt32 sema,readSema,writeSema;
***************
*** 801,805 ****
}
epi = (EPInfo *) s->privateSocketPtr;
! DoBind(epi,0,(InetPort) port,TCPListenerSocketType,(OTQLen) backlogSize);
if (port != 0 && epi->localAddress.fPort != port) {//The port we wanted must match, otherwise we die
sqSocketDestroy(s);
--- 806,810 ----
}
epi = (EPInfo *) s->privateSocketPtr;
! DoBind(epi,addr,(InetPort) port,TCPListenerSocketType,(OTQLen) backlogSize);
if (port != 0 && epi->localAddress.fPort != port) {//The port we wanted must match, otherwise we die
sqSocketDestroy(s);
|