2005/8/11, Henning Brauer <[EMAIL PROTECTED]>: > sockaddr_in would suffice, but it is bad style. with sockaddr_storage, > you ar eon the safe side, even when you add v6 support later, or v8, or > whatever the future brings, so play safe and use sockaddr_storage, > that's what it is for.
Thanks. Yes, I don't want my server to crash when accepting some manipulated packets, so I will use sockaddr_storage. (I just didn't want to do something too stupid, that's why I asked) > > BTW neither write(2) nor accept(2) mention EINTR even though > > that value appears in /usr/src/lib/libpthread/uthread/uthread_*.c > > (I used a sendbug to report it this morning, but didn't get a reply). > > basically every system call can be interrupted and thus fail with EINTR What about SA_RESTART? Can it be relied on to restart poll(), accept(), read() and writev() when I for example use SIGHUP to reload config files? Or should I better always check for EINTR? Why don't you use sigaction at all in ntpd and bgpd? Regards Alex

