. INADDR_NONE is -1 . Change bindport to an unsigned short (ntohs implies short). . Conditionally implement our own errx() and err(). . Conditionally use a custom vasprintf() that depends on vsnprintf().