Dear Hurd porters,

why does

#include <stdio.h>
#include <sys/socket.h>

int
main (void)
{
        unsigned int optval;
        socklen_t optlen = sizeof optval;
        int rc, s;

        s = socket (AF_UNIX, SOCK_STREAM, 0);
        if (s == -1) {
                perror ("socket");
                return 1;
        }
        rc = getsockopt (s, SOL_SOCKET, SO_SNDBUF, &optval, &optlen);
        if (rc) {
                perror ("getsockopt");
                return 1;
        }
        if (optlen == sizeof optval) {
                printf ("SNDBUF: %u\n", optval);
        } else {
                printf ("optlen = %ul\n", optlen);
        }
        return 0;
}

fail on Hurd like

wferi@exodar:~$ ./sndbuf 
getsockopt: Protocol not available

?
-- 
Thanks,
Feri

Reply via email to