Re: HELP: select() under sockets

Michael Meissner (rti!xyzzy!
21 Sep 87 15:17:25 GMT

In article <> ron@topaz.rutgers.EDU (Ron Natalie) writes:
> The other arguments to select are pointers to bit fields so assumably
> char buf[10];
> select(80, buf, (char *) 0, (char *) 0, (char *) 0, (time_t) 0)

In 4.2 systems the three pointer arguments are pointers to INT's, not char's.
In 4.3 this was changed to be the type fd_set (declared in sys/types.h), which
is a structure big enough to hold 256 file descriptors, with a way to expand
it further. In no case is a character array used. This may be seen as picking
nits, but it becomes important on machines that have different representations
for pointers to char's and other pointers.

Michael	Meissner, Data General.		Uucp: ...!mcnc!rti!xyzzy!meissner
					Arpa/Csnet:  meissner@dg-rtp.DG.COM

This archive was generated by hypermail 2.0b3 on Thu Mar 09 2000 - 14:39:16 GMT