From 0f87d7cb6868da710d5f23bcdcd5a459d18435fc Mon Sep 17 00:00:00 2001 From: kuangniu Date: Fri, 24 Jan 2020 14:06:45 +0900 Subject: [PATCH] Fix sockopt level. --- src/udprelay.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/udprelay.c b/src/udprelay.c index ba6b6cff..696003f9 100644 --- a/src/udprelay.c +++ b/src/udprelay.c @@ -521,7 +521,7 @@ create_server_socket(const char *host, const char *port) exit(EXIT_FAILURE); } - if (setsockopt(server_sock, SOL_IP, flag_r, &opt, sizeof(opt))) { + if (setsockopt(server_sock, sol, flag_r, &opt, sizeof(opt))) { FATAL("[udp] setsockopt IP_RECVORIGDSTADDR"); } #endif