Wondering about raw sockets.

2003-02-28 Thread ianf
Hi Does anyone know why this behaviour is not a bug? sock_raw = socket(PF_INET, SOCK_RAW, IPPROTO_RAW); optval = 1; setsockopt(sock_raw, IPPROTO_IP, IP_HDRINCL, (char *)&optval, sizeof(optval)); peer.sin_family = AF_INET; peer.sin_addr.s_addr = (CAST_HDR(packet))->dest; peer.sin_port = (CAST_UDP(

Re: write(2) SIGPIPE on a closed socket?

2003-03-19 Thread ianf
Bruce Evans wrote: > On Wed, 19 Mar 2003, Peter Pentchev wrote: > > > Actually, I wonder if I have answered my own question. dnscache seems > > to use poll(2), and it would be poll(2)'s task to notify the program of > > any exceptional (error) conditions. I wonder if it is possible that > > dnsc