aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/core/lib
diff options
context:
space:
mode:
authorGravatar Yash Tibrewal <yashkt@google.com>2018-11-27 17:14:08 -0800
committerGravatar Yash Tibrewal <yashkt@google.com>2018-11-27 17:14:08 -0800
commitfe9ba9adf8429687ef3d524ec8fc91a18e03f625 (patch)
treee80903d795707139eec4600745cabad2d6e342b9 /src/core/lib
parent66b2005cbb322bc1d783b90a574b0e14df906bcb (diff)
Always set fd to be readable/writable on receiving EPOLLERR
Diffstat (limited to 'src/core/lib')
-rw-r--r--src/core/lib/iomgr/tcp_posix.cc14
1 files changed, 6 insertions, 8 deletions
diff --git a/src/core/lib/iomgr/tcp_posix.cc b/src/core/lib/iomgr/tcp_posix.cc
index cb4c9db7a6..4a5ca615e5 100644
--- a/src/core/lib/iomgr/tcp_posix.cc
+++ b/src/core/lib/iomgr/tcp_posix.cc
@@ -740,7 +740,7 @@ static bool process_errors(grpc_tcp* tcp) {
}
return false;
}
- process_timestamp(tcp, &msg, cmsg);
+ cmsg = process_timestamp(tcp, &msg, cmsg);
}
}
}
@@ -761,13 +761,11 @@ static void tcp_handle_error(void* arg /* grpc_tcp */, grpc_error* error) {
/* We are still interested in collecting timestamps, so let's try reading
* them. */
- if (!process_errors(tcp)) {
- /* This was not a timestamps error. This was an actual error. Set the
- * read and write closures to be ready.
- */
- grpc_fd_set_readable(tcp->em_fd);
- grpc_fd_set_writable(tcp->em_fd);
- }
+ process_errors(tcp);
+ /* This might not a timestamps error. Set the read and write closures to be
+ * ready. */
+ grpc_fd_set_readable(tcp->em_fd);
+ grpc_fd_set_writable(tcp->em_fd);
GRPC_CLOSURE_INIT(&tcp->error_closure, tcp_handle_error, tcp,
grpc_schedule_on_exec_ctx);
grpc_fd_notify_on_error(tcp->em_fd, &tcp->error_closure);