4 ms·
>server_socket_getport I found this interesting article: http://daniel.haxx.se/blog/2014/10/25/pretending-port-zero-is-a-normal-one/ http://daniel.haxx.se/blog
by cremno 12y ago
>server_socket_getport
I found this interesting article: http://daniel.haxx.se/blog/2014/10/25/pretending-port-zero-is-a-normal-one/ http://daniel.haxx.se/blog/2014/10/25/pretending-port-zero-i...
So since 0 can be okay and (in_port_t)-1 (=65535) is okay, it has to be changed to return int and take a in_port_t* to be acceptable for you. The return value may not even matter if only AF_INET/AF_INET6 as family is possible - a comment could be of help here.