Mercurial > hg > nginx
comparison src/os/unix/ngx_socket.c @ 93:738fe44c70d5
nginx-0.0.1-2003-05-21-17:28:21 import
author | Igor Sysoev <igor@sysoev.ru> |
---|---|
date | Wed, 21 May 2003 13:28:21 +0000 |
parents | e8cdc2989cee |
children | 2e069b6e6920 |
comparison
equal
deleted
inserted
replaced
92:19cc647ecd91 | 93:738fe44c70d5 |
---|---|
1 | 1 |
2 #include <ngx_socket.h> | 2 #include <ngx_socket.h> |
3 | 3 |
4 | 4 |
5 /* ioctl(FIONBIO) set blocking mode with one syscall only while | 5 /* |
6 ioctl(FIONBIO) set blocking mode with one syscall only while | |
6 fcntl(F_SETFL, ~O_NONBLOCK) need to know previous state | 7 fcntl(F_SETFL, ~O_NONBLOCK) need to know previous state |
7 using fcntl(F_GETFL). | 8 using fcntl(F_GETFL). |
8 On FreeBSD both are syscall */ | |
9 | 9 |
10 #ifdef __FreeBSD__ | 10 ioctl() and fcntl() are syscalls on FreeBSD, Solaris 7/8 and Linux |
11 */ | |
12 | |
13 #if 1 | |
11 | 14 |
12 int ngx_nonblocking(ngx_socket_t s) | 15 int ngx_nonblocking(ngx_socket_t s) |
13 { | 16 { |
14 unsigned long nb = 1; | 17 unsigned long nb = 1; |
15 | 18 |