Fix: Use SOL_SOCKET level for SO_KEEPALIVE on all platform
authorJonathan Rajotte <jonathan.rajotte-julien@efficios.com>
Wed, 21 Feb 2018 21:59:54 +0000 (16:59 -0500)
committerJérémie Galarneau <jeremie.galarneau@efficios.com>
Tue, 27 Feb 2018 15:09:15 +0000 (10:09 -0500)
commitb8966fd24eeca6d5a11ff94a63568b527056d643
tree563f71ccacc2ee01ce91f9adde199a06de59d7f2
parenta798f0b9e90ece41ef78d89f707264561cf2c79e
Fix: Use SOL_SOCKET level for SO_KEEPALIVE on all platform

On Linux, COMPAT_SOCKET_LEVEL was set to SOL_TCP instead
of SOL_SOCKET, this resulted in execution of:
    setsockopt(..., SOL_TCP, TCP_DEFER_ACCEPT, ...)

Instead of:
    setsockopt(..., SOL_SOCKET, SO_KEEPALIVE, ...)

Hence, TCP keep alive was not enabled.

COMPAT_SOCKET_LEVEL is not needed. All platforms supported use the
SOL_SOCKET level for SO_KEEPALIVE.

Signed-off-by: Jonathan Rajotte <jonathan.rajotte-julien@efficios.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
src/bin/lttng-relayd/tcp_keep_alive.c
This page took 0.024714 seconds and 4 git commands to generate.