Technically, not as the standard says that should not happen; though the thread may be woken up with the condition variable still false (spurious wake-up). That said, unfortunately, not all kernels obey that standard either by design or by bug from what I gleaned from the web. So, it's best to check for it anyway. However, even if you didn't check for EINTR, a wakeup for any reason (other than a plain immediate error) requires that you check the condition variable and if false re-issue the wait with a modified timeout (if so needed). So, there really is no reason to specifically test for EINTR as it's covered under the spurious wake-up rule. Andy On Tue, 6 May 2014, Lukasz Janyst wrote: > Can `pthread_cond_timedwait` be interrupted by a signal handler? Exit with `EINTR`? > > --- > Reply to this email directly or view it on GitHub: > https://github.com/xrootd/xrootd/pull/111#issuecomment-42297677 --- Reply to this email directly or view it on GitHub: https://github.com/xrootd/xrootd/pull/111#issuecomment-42324518 ######################################################################## Use REPLY-ALL to reply to list To unsubscribe from the XROOTD-DEV list, click the following link: https://listserv.slac.stanford.edu/cgi-bin/wa?SUBED1=XROOTD-DEV&A=1