diff options
author | 2018-08-21 11:59:24 -0700 | |
---|---|---|
committer | 2018-08-21 11:59:24 -0700 | |
commit | 2f8e60a7737293a3e44f555ac9de92267785e91f (patch) | |
tree | d23eac902eea669821f4002ee905d1bb50161bf8 /src/core/lib/iomgr/tcp_server_utils_posix_common.cc | |
parent | ccc6ee3db0924e6f6e9aa1c8ccd60d7e562e6615 (diff) |
Set TCP_USER_TIMEOUT socket option
Diffstat (limited to 'src/core/lib/iomgr/tcp_server_utils_posix_common.cc')
-rw-r--r-- | src/core/lib/iomgr/tcp_server_utils_posix_common.cc | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/core/lib/iomgr/tcp_server_utils_posix_common.cc b/src/core/lib/iomgr/tcp_server_utils_posix_common.cc index b9f8145572..2cb28f2e03 100644 --- a/src/core/lib/iomgr/tcp_server_utils_posix_common.cc +++ b/src/core/lib/iomgr/tcp_server_utils_posix_common.cc @@ -166,6 +166,8 @@ grpc_error* grpc_tcp_server_prepare_socket(grpc_tcp_server* s, int fd, if (err != GRPC_ERROR_NONE) goto error; err = grpc_set_socket_reuse_addr(fd, 1); if (err != GRPC_ERROR_NONE) goto error; + err = grpc_set_socket_tcp_user_timeout(fd, 0); + if (err != GRPC_ERROR_NONE) goto error; } err = grpc_set_socket_no_sigpipe_if_possible(fd); if (err != GRPC_ERROR_NONE) goto error; |