Branch: Tag:

2020-05-01

2020-05-01 12:12:28 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Stdio: query_mtu() is now guarded by IP_MTU.

IP_MTU seems to be Linux-specific, and I haven't been able
to find corresponding code for other OSes.

Fixes build failures on multiple platforms.

5504:    }   }    + #ifdef IP_MTU   /*! @decl int query_mtu()    *!    *! Get the Max Transfer Unit for the object (if any).
5536:       if (SOCKADDR_FAMILY(addr) == AF_INET) {    level = IPPROTO_IP; + #ifdef IPV6_MTU    } else if (SOCKADDR_FAMILY(addr) == AF_INET6) {    level = IPPROTO_IPV6;    option = IPV6_MTU; -  + #endif    }       len = sizeof(mtu);
5549:    }    push_int(mtu);   } + #endif /* IP_MTU */      /*! @decl void create(string filename)    *! @decl void create(string filename, string mode)