Mercurial > hg > xemacs-beta
comparison lib-src/gnuslib.c @ 155:43dd3413c7c7 r20-3b4
Import from CVS: tag r20-3b4
author | cvs |
---|---|
date | Mon, 13 Aug 2007 09:39:39 +0200 |
parents | 538048ae2ab8 |
children | 929b76928fce |
comparison
equal
deleted
inserted
replaced
154:94141801dd7e | 155:43dd3413c7c7 |
---|---|
105 return -1; /* hostarg should always be NULL for SYSV_IPC */ | 105 return -1; /* hostarg should always be NULL for SYSV_IPC */ |
106 #endif | 106 #endif |
107 } else { | 107 } else { |
108 /* no hostname given. Use unix-domain/sysv-ipc, or | 108 /* no hostname given. Use unix-domain/sysv-ipc, or |
109 * internet-domain connection to local host if they're not available. */ | 109 * internet-domain connection to local host if they're not available. */ |
110 #ifdef UNIX_DOMAIN_SOCKETS | 110 #if defined(UNIX_DOMAIN_SOCKETS) |
111 *s = connect_to_unix_server(); | 111 *s = connect_to_unix_server(); |
112 return (int) CONN_UNIX; | 112 return (int) CONN_UNIX; |
113 #endif | 113 #elif defined(SYSV_IPC) |
114 #ifdef SYSV_IPC | |
115 *s = connect_to_ipc_server(); | 114 *s = connect_to_ipc_server(); |
116 return (int) CONN_IPC; | 115 return (int) CONN_IPC; |
117 #endif | 116 #elif defined(INTERNET_DOMAIN_SOCKETS) |
118 #ifdef INTERNET_DOMAIN_SOCKETS | |
119 gethostname(localhost,HOSTNAMSZ); /* use this host by default */ | 117 gethostname(localhost,HOSTNAMSZ); /* use this host by default */ |
120 *s = connect_to_internet_server(localhost, portarg); | 118 *s = connect_to_internet_server(localhost, portarg); |
121 return (int) CONN_INTERNET; | 119 return (int) CONN_INTERNET; |
122 #endif | 120 #endif /* IPC type */ |
123 } | 121 } |
124 } | 122 } |
125 | 123 |
126 #ifdef SYSV_IPC | 124 #ifdef SYSV_IPC |
127 /* | 125 /* |