mirror of
https://github.com/yarrick/iodine.git
synced 2025-10-17 08:41:53 +00:00
Fix (ignore) Dont-Fragment for OpenBSD and OS X
This commit is contained in:
@@ -130,9 +130,11 @@ open_dns(int localport, in_addr_t listen_ip)
|
||||
setsockopt(fd, IPPROTO_IP, DSTADDR_SOCKOPT, (const void*) &flag, sizeof(flag));
|
||||
#endif
|
||||
|
||||
#ifdef IP_OPT_DONT_FRAG
|
||||
/* Set dont-fragment ip header flag */
|
||||
flag = DONT_FRAG_VALUE;
|
||||
setsockopt(fd, IPPROTO_IP, IP_OPT_DONT_FRAG, (const void*) &flag, sizeof(flag));
|
||||
#endif
|
||||
|
||||
if(bind(fd, (struct sockaddr*)&addr, sizeof(addr)) < 0)
|
||||
err(1, "bind");
|
||||
|
Reference in New Issue
Block a user