httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Brian Clapper <>
Subject Re: 504 Gateway Timeout: another thing for the wish list
Date Mon, 29 Jan 1996 18:42:45 GMT
>>>>> "Nathan" == Nathan Schrenk <> writes:

Nathan> On Mon, 29 Jan 1996, David Robinson wrote:
>> Question: is poll() available on all Unixes?

Nathan> poll() is an SVR4 thing.  In _Advanced Programming in the Unix
Nathan> Environment_, Stevens says "The SVR4 poll function is similar to
Nathan> select(), but the programmer interface is different.  As we'll see,
Nathan> poll is tied to the streams system, although in SVR4 we are able to
Nathan> use it with any descriptor."

There are a few useful critters that want `poll' instead of `select'; Tom
Fitzgerald's `udprelay' is one of them (at least, the version I used had no
support for `select').  My solution to that dilemma was to write a `poll'
emulator in terms of select; the task is one of simple mapping, and the
aforementioned Stevens book is a good resource.  Actually, SVR4.2 is
guaranteed to have both `poll' *and* `select', since an SVR4.2-compliant
system (Solaris, UnixWare, etc.) must provide both System V and Berkeley
semantics.  (Whether it provides them *reasonably* is another matter
entirely.)  Moral: Right now, at least, your code will be more portable if
you use `select'.

(BTW, you can have my poll emulator if you want.)
Brian Clapper,,
Nothing astonishes men so much as common sense and plain dealing.

View raw message