Subversion Repositories Tewi

Rev

Rev 274 | Rev 276 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 274 Rev 275
Line 1... Line 1...
1
/* $Id: server.c 274 2024-10-08 10:55:19Z nishi $ */
1
/* $Id: server.c 275 2024-10-08 11:00:48Z nishi $ */
2
 
2
 
3
#define SOURCE
3
#define SOURCE
4
 
4
 
5
#include "../config.h"
5
#include "../config.h"
6
 
6
 
Line 155... Line 155...
155
		if(setsockopt(sock, SOL_SOCKET, SO_REUSEADDR, (void*)&yes, sizeof(yes)) < 0) {
155
		if(setsockopt(sock, SOL_SOCKET, SO_REUSEADDR, (void*)&yes, sizeof(yes)) < 0) {
156
			close_socket(sock);
156
			close_socket(sock);
157
			cm_log("Server", "setsockopt failure (reuseaddr)");
157
			cm_log("Server", "setsockopt failure (reuseaddr)");
158
			return 1;
158
			return 1;
159
		}
159
		}
160
#ifndef __PPU__
-
 
161
#ifdef __minix
160
#if !defined(__PPU__) && !defined(__minix)
162
		if(setsockopt(sock, 0, TCP_NODELAY, (void*)&yes, sizeof(yes)) < 0) {
-
 
163
#else
-
 
164
		if(setsockopt(sock, IPPROTO_TCP, TCP_NODELAY, (void*)&yes, sizeof(yes)) < 0) {
161
		if(setsockopt(sock, IPPROTO_TCP, TCP_NODELAY, (void*)&yes, sizeof(yes)) < 0) {
165
#endif
162
#endif
166
			close_socket(sock);
163
			close_socket(sock);
167
			cm_log("Server", "setsockopt failure (nodelay)");
164
			cm_log("Server", "setsockopt failure (nodelay)");
168
			return 1;
165
			return 1;