Skip to content
Snippets Groups Projects
Commit d64ed6a3 authored by Craig Tiller's avatar Craig Tiller
Browse files

Merge pull request #3397 from nicolasnoble/shutdown-win32-warning

Shutting down warning about operations on closed sockets.
parents d56c8bb0 3a26c5bb
No related branches found
No related tags found
No related merge requests found
......@@ -144,7 +144,7 @@ static int on_read(grpc_tcp *tcp, int success) {
int do_abort = 0;
if (success) {
if (socket->read_info.wsa_error != 0) {
if (socket->read_info.wsa_error != 0 && !tcp->shutting_down) {
if (socket->read_info.wsa_error != WSAECONNRESET) {
char *utf8_message = gpr_format_message(info->wsa_error);
gpr_log(GPR_ERROR, "ReadFile overlapped error: %s", utf8_message);
......@@ -153,7 +153,7 @@ static int on_read(grpc_tcp *tcp, int success) {
success = 0;
gpr_slice_unref(tcp->read_slice);
} else {
if (info->bytes_transfered != 0) {
if (info->bytes_transfered != 0 && !tcp->shutting_down) {
sub = gpr_slice_sub_no_ref(tcp->read_slice, 0, info->bytes_transfered);
gpr_slice_buffer_add(tcp->read_slices, sub);
success = 1;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment