unix: pass error to write callback in stream cleanup
This commit is contained in:
parent
4487531b06
commit
3c0684e832
@ -129,8 +129,8 @@ void uv__stream_destroy(uv_stream_t* stream) {
|
||||
|
||||
req = ngx_queue_data(q, uv_write_t, queue);
|
||||
if (req->cb) {
|
||||
uv_err_new_artificial(req->handle->loop, UV_OK);
|
||||
req->cb(req, 0);
|
||||
uv_err_new_artificial(stream->loop, req->error);
|
||||
req->cb(req, req->error ? -1 : 0);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user