1.0.42.50: workaround a Darwin nanosleep() bug
Fixes lp#640516.
It turns out that on Darwin, if a nanosleep() call is interrupted,
and the signal handler takes longer than the requested sleep time
was, then the call will return with EINTR and (unsigned)-1 in the
remaining seconds.
Since we call nanosleep() again when it returns with EINTR with the
remaining time, this would cause us to sleep ~136 years...
So, check that the remainder is not increasing before calling
nanosleep() again.
Many, many thanks to Joe Lobraco who reported and diagnosed the
issue.