Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: $Revision: 1.6.2.14 $; site siemens.UUCP Path: utzoo!watmath!clyde!burl!ulysses!allegra!princeton!siemens!lrr From: lrr@siemens.UUCP Newsgroups: net.unix Subject: Re: AF_INET sockets, code examples neede Message-ID: <24900010@siemens.UUCP> Date: Thu, 20-Jun-85 09:09:00 EDT Article-I.D.: siemens.24900010 Posted: Thu Jun 20 09:09:00 1985 Date-Received: Fri, 21-Jun-85 00:44:55 EDT References: <240@greipa.UUCP> Lines: 12 Nf-ID: #R:greipa:-24000:siemens:24900010:000:459 Nf-From: siemens!lrr Jun 20 09:09:00 1985 Without trying your code, haven't you committed a C sin by failing to parenthesize the "nf = accept(fd, (caddr_t)&sin, &sz)" part? Isn't the relation "accept(...) < 0" computed first and the result assigned to nf? If accept is working, then the condition is false (0) so nf has the value 0, and that's what you got. I think that's it. Larry Rogers Siemens Research and Technology Laboratories Princeton, NJ 08540 princeton!siemens!jaguar!lrr 609 734 6559