|
|
@ -460,9 +460,12 @@ create_server_socket(const char *host, const char *port) |
|
|
|
ERROR("[udp] setsockopt IP_TRANSPARENT"); |
|
|
|
exit(EXIT_FAILURE); |
|
|
|
} |
|
|
|
if (setsockopt(server_sock, IPPROTO_IP, IP_RECVORIGDSTADDR, &opt, sizeof(opt))) { |
|
|
|
if (setsockopt(server_sock, SOL_IP, IP_RECVORIGDSTADDR, &opt, sizeof(opt))) { |
|
|
|
FATAL("[udp] setsockopt IP_RECVORIGDSTADDR"); |
|
|
|
} |
|
|
|
if (setsockopt(server_sock, SOL_IPV6, IPV6_RECVORIGDSTADDR, &opt, sizeof(opt))) { |
|
|
|
FATAL("[udp] setsockopt IPV6_RECVORIGDSTADDR"); |
|
|
|
} |
|
|
|
#endif |
|
|
|
|
|
|
|
s = bind(server_sock, rp->ai_addr, rp->ai_addrlen); |
|
|
|