mirror of
https://github.com/systemd/systemd.git
synced 2026-07-25 08:45:56 +00:00
socket: fix setsockopt call. SOL_SOCKET changed to SOL_TCP.
This commit is contained in:
@@ -839,7 +839,7 @@ static void socket_apply_socket_options(Socket *s, int fd) {
|
||||
|
||||
if (s->keep_alive_cnt) {
|
||||
int value = s->keep_alive_cnt;
|
||||
if (setsockopt(fd, SOL_SOCKET, TCP_KEEPCNT, &value, sizeof(value)) < 0)
|
||||
if (setsockopt(fd, SOL_TCP, TCP_KEEPCNT, &value, sizeof(value)) < 0)
|
||||
log_unit_warning_errno(UNIT(s), errno, "TCP_KEEPCNT failed: %m");
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user