iomgr_timeout.tv_sec = 100000000;
iomgr_timeout.tv_usec = 0;
}
-#ifdef AFS_NT40_ENV
+#if defined(AFS_NT40_ENV) || defined(AFS_LINUX24_ENV)
/* On NT, signals don't interrupt a select call. So this can potentially
* lead to long wait times before a signal is honored. To avoid this we
* dont do select() for longer than IOMGR_MAXWAITTIME (5 secs) */
+ /* Whereas Linux seems to sometimes "lose" signals */
if (iomgr_timeout.tv_sec > (IOMGR_MAXWAITTIME - 1)) {
iomgr_timeout.tv_sec = IOMGR_MAXWAITTIME;
iomgr_timeout.tv_usec = 0;
/* Real timeout only if signal handler hasn't set
iomgr_timeout to zero. */
-#ifdef AFS_NT40_ENV
+#if defined(AFS_NT40_ENV) || defined(AFS_LINUX24_ENV)
/* On NT, real timeout only if above and if iomgr_timeout
* interval is equal to timeout interval (i.e., not adjusted
* to check for pseudo-signals).
*/
+ /* And also for Linux as above */
if (iomgr_timeout.tv_sec != timeout.tv_sec ||
iomgr_timeout.tv_usec != timeout.tv_usec) {
/* signal check interval timed out; not real timeout */
extern PROCESS LWP_ThreadId(void);
#endif
+#ifdef AFS_LINUX24_ENV
+/* max time we are allowed to spend in a select call on Linux to avoid
+ lost signal issues */
+#define IOMGR_MAXWAITTIME 60 /* seconds */
+#else
/* max time we are allowed to spend in a select call on NT */
#define IOMGR_MAXWAITTIME 5 /* seconds */
+#endif
/* max time we spend on a select in a Win95 DOS box */
#define IOMGR_WIN95WAITTIME 5000 /* microseconds */