pgsql-bugs(at)postgresql(dot)org writes:
> In the libpq C interface, PQconnectdb results in a SEGV when the conn->sock number is greater than __FD_SETSIZE (1024 on linux). The crash is caused by stack corruption when attempting to FD_SET.
<blink> Shouldn't you be filing this bug against libc? Seems to me the
left hand is not talking to the right hand, if open() can return FDs
that don't work with select().
regards, tom lane