diff -ur src/comm.c newsrc/comm.c --- src/comm.c Fri Jul 19 19:57:51 1996 +++ newsrc/comm.c Tue Nov 11 21:03:58 1997 @@ -30,7 +30,6 @@ /* * This file contains all of the OS-dependent stuff: - * startup, signals, BSD sockets for tcp/ip, i/o, timing. * * The data flow for input is: * Game_loop ---> Read_from_descriptor ---> Read @@ -42,6 +41,10 @@ * The OS-dependent functions are Read_from_descriptor and Write_to_descriptor. * -- Furey 26 Jan 1993 */ +/* + * IP Binding Patch by Bobby Bailey (wordweaver@usa.net) + */ + #if defined(macintosh) #include <types.h> @@ -117,9 +120,11 @@ #include <netinet/in.h> #include <sys/socket.h> #include "telnet.h" +#include <arpa/inet.h> const char echo_off_str [] = { IAC, WILL, TELOPT_ECHO, '\0' }; const char echo_on_str [] = { IAC, WONT, TELOPT_ECHO, '\0' }; const char go_ahead_str [] = { IAC, GA, '\0' }; +#define IP_SERVER "localhost" #endif @@ -473,6 +478,8 @@ sa = sa_zero; sa.sin_family = AF_INET; sa.sin_port = htons( port ); + sa.sin_addr.s_addr = inet_addr(IP_SERVER); + if ( bind( fd, (struct sockaddr *) &sa, sizeof(sa) ) < 0 ) {