Merge branch 'v0.8'
Conflicts: include/uv.h
This commit is contained in:
commit
a3c6a485c6
@ -120,9 +120,10 @@ extern "C" {
|
|||||||
XX( 53, ENOTEMPTY, "directory not empty") \
|
XX( 53, ENOTEMPTY, "directory not empty") \
|
||||||
XX( 54, ENOSPC, "no space left on device") \
|
XX( 54, ENOSPC, "no space left on device") \
|
||||||
XX( 55, EIO, "i/o error") \
|
XX( 55, EIO, "i/o error") \
|
||||||
XX( 56, EROFS, "read-only file system" ) \
|
XX( 56, EROFS, "read-only file system") \
|
||||||
XX( 57, ENODEV, "no such device" ) \
|
XX( 57, ENODEV, "no such device") \
|
||||||
XX( 58, ECANCELED, "operation canceled" )
|
XX( 58, ESPIPE, "invalid seek") \
|
||||||
|
XX( 59, ECANCELED, "operation canceled") \
|
||||||
|
|
||||||
|
|
||||||
#define UV_ERRNO_GEN(val, name, s) UV_##name = val,
|
#define UV_ERRNO_GEN(val, name, s) UV_##name = val,
|
||||||
|
|||||||
@ -68,6 +68,7 @@ uv_err_code uv_translate_sys_error(int sys_errno) {
|
|||||||
case EAFNOSUPPORT: return UV_EAFNOSUPPORT;
|
case EAFNOSUPPORT: return UV_EAFNOSUPPORT;
|
||||||
case EBADF: return UV_EBADF;
|
case EBADF: return UV_EBADF;
|
||||||
case EPIPE: return UV_EPIPE;
|
case EPIPE: return UV_EPIPE;
|
||||||
|
case ESPIPE: return UV_ESPIPE;
|
||||||
case EAGAIN: return UV_EAGAIN;
|
case EAGAIN: return UV_EAGAIN;
|
||||||
#if EWOULDBLOCK != EAGAIN
|
#if EWOULDBLOCK != EAGAIN
|
||||||
case EWOULDBLOCK: return UV_EAGAIN;
|
case EWOULDBLOCK: return UV_EAGAIN;
|
||||||
|
|||||||
@ -86,6 +86,10 @@ void uv__udp_finish_close(uv_udp_t* handle) {
|
|||||||
req = ngx_queue_data(q, uv_udp_send_t, queue);
|
req = ngx_queue_data(q, uv_udp_send_t, queue);
|
||||||
uv__req_unregister(handle->loop, req);
|
uv__req_unregister(handle->loop, req);
|
||||||
|
|
||||||
|
if (req->bufs != req->bufsml)
|
||||||
|
free(req->bufs);
|
||||||
|
req->bufs = NULL;
|
||||||
|
|
||||||
if (req->send_cb) {
|
if (req->send_cb) {
|
||||||
/* FIXME proper error code like UV_EABORTED */
|
/* FIXME proper error code like UV_EABORTED */
|
||||||
uv__set_artificial_error(handle->loop, UV_EINTR);
|
uv__set_artificial_error(handle->loop, UV_EINTR);
|
||||||
@ -171,6 +175,7 @@ static void uv__udp_run_completed(uv_udp_t* handle) {
|
|||||||
|
|
||||||
if (req->bufs != req->bufsml)
|
if (req->bufs != req->bufsml)
|
||||||
free(req->bufs);
|
free(req->bufs);
|
||||||
|
req->bufs = NULL;
|
||||||
|
|
||||||
if (req->send_cb == NULL)
|
if (req->send_cb == NULL)
|
||||||
continue;
|
continue;
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user