This project is closed and read-only.
Backport #1567 » ruby-1.9.1-p129-socket_listen_2.patch
| ruby-1.9.1-p129/ext/socket/socket.c 2009-06-04 21:04:48.000000000 -0500 | ||
|---|---|---|
|
} else
|
||
|
break;
|
||
|
}
|
||
|
if (status >= 0 && type == INET_SERVER) {
|
||
|
status = listen(fd, 5);
|
||
|
syscall = "listen(2)";
|
||
|
}
|
||
|
if (status < 0) {
|
||
|
close(fd);
|
||
|
rb_sys_fail(syscall);
|
||
|
}
|
||
|
arg->fd = -1;
|
||
|
if (type == INET_SERVER)
|
||
|
listen(fd, 5);
|
||
|
/* create new instance */
|
||
|
return init_sock(arg->sock, fd);
|
||
|
}
|
||
| ... | ... | |
|
rb_sys_fail(sockaddr.sun_path);
|
||
|
}
|
||
|
if (server) listen(fd, 5);
|
||
|
if (server) {
|
||
|
if (listen(fd, 5) < 0) {
|
||
|
close(fd);
|
||
|
rb_sys_fail("listen(2)");
|
||
|
}
|
||
|
}
|
||
|
init_sock(sock, fd);
|
||
|
if (server) {
|
||
- « Previous
- 1
- 2
- Next »