James Leigh <james.leigh@ottawa.com> writes:
> I have been having some trouble with using PQnotifies and the select
> function. When I run the program below, the select function returns
> early (before 5sec) when I send it a notify; but once the select
> function runs out the first time (after 5sec), then no matter how many
> time I send anotify the select does not return until after the full 5
> secs.
You're forgetting that the rdfs parameter to select() is a read/write
parameter. You need to set the bit for the file you're interested in
every time through the loop, not just once.
regards, tom lane