|
|
@ -186,15 +186,13 @@ void uv_pipe_connect(uv_connect_t* req, |
|
|
|
uv_strlcpy(saddr.sun_path, name, sizeof(saddr.sun_path)); |
|
|
|
saddr.sun_family = AF_UNIX; |
|
|
|
|
|
|
|
/* We don't check for EINPROGRESS. Think about it: the socket
|
|
|
|
* is either there or not. |
|
|
|
*/ |
|
|
|
do { |
|
|
|
r = connect(handle->fd, (struct sockaddr*)&saddr, sizeof saddr); |
|
|
|
} |
|
|
|
while (r == -1 && errno == EINTR); |
|
|
|
|
|
|
|
if (r == -1) |
|
|
|
if (errno != EINPROGRESS) |
|
|
|
goto out; |
|
|
|
|
|
|
|
if (new_sock) |
|
|
@ -216,7 +214,8 @@ out: |
|
|
|
req->cb = cb; |
|
|
|
ngx_queue_init(&req->queue); |
|
|
|
|
|
|
|
/* Run callback on next tick. */ |
|
|
|
/* Force callback to run on next tick in case of error. */ |
|
|
|
if (err != 0) |
|
|
|
uv__io_feed(handle->loop, &handle->write_watcher, UV__IO_WRITE); |
|
|
|
|
|
|
|
/* Mimic the Windows pipe implementation, always
|
|
|
|