At least on HPUX, select with delay.tv_sec = 0 and delay.tv_usec = 1000000

Tom Lane <tgl@sss.pgh.pa.us>

Commit: 496ea7a87633a64ddab65b375e0be56fa60873cc
Author: Tom Lane <tgl@sss.pgh.pa.us>
Date: 2001-02-24T22:42:45Z
Releases: 7.1.1
At least on HPUX, select with delay.tv_sec = 0 and delay.tv_usec = 1000000
does not lead to a one-second delay, but to an immediate EINVAL failure.
This causes CHECKPOINT to crash with s_lock_stuck much too quickly :-(.
Fix by breaking down the requested wait div/mod 1e6.

Files

PathChange+/−
src/backend/storage/buffer/s_lock.c modified +3 −3