tasks. The select() listens to these file descriptors. */
SILC_SCHEDULE_SELECT_TASKS;
- if (schedule.max_fd == -1) {
- /*SILC_LOG_ERROR(("Nothing to listen, exiting"));*/
+ if (schedule.max_fd == -1 && !schedule.timeout)
return FALSE;
- }
if (schedule.timeout) {
SILC_LOG_DEBUG(("timeout: sec=%d, usec=%d", schedule.timeout->tv_sec,
}
/* Start the scheduler loop */
- while (silc_schedule_one(-1)) ;
+ while (silc_schedule_one(-1))
+ ;
}
GNU General Public License for more details.
*/
-/*
- * $Id$
- * $Log$
- * Revision 1.1 2000/09/13 17:45:16 priikone
- * Splitted SILC core library. Core library includes now only
- * SILC protocol specific stuff. New utility library includes the
- * old stuff from core library that is more generic purpose stuff.
- *
- * Revision 1.2 2000/07/05 06:06:35 priikone
- * Global cosmetic change.
- *
- * Revision 1.1.1.1 2000/06/27 11:36:55 priikone
- * Imported from internal CVS/Added Log headers.
- *
- *
- */
+/* $Id$ */
#include "silcincludes.h"
SilcTaskType type, SilcTaskPriority priority)
{
SilcTask new;
- int timeout = 0;
+ int timeout = FALSE;
SILC_LOG_DEBUG(("Registering new task, fd=%d type=%d priority=%d",
fd, type, priority));
new->timeout.tv_sec += 1;
new->timeout.tv_usec -= 1000000L;
}
- timeout = 1;
+ timeout = TRUE;
}
/* Is this first task of the queue? */