mirror of
https://gitlab.com/chrony/chrony.git
synced 2025-12-04 16:35:07 -05:00
Replace LOG_FATAL call with assert in SCH_MailLoop
This commit is contained in:
7
sched.c
7
sched.c
@@ -589,10 +589,7 @@ SCH_MainLoop(void)
|
|||||||
|
|
||||||
/* if there are no file descriptors being waited on and no
|
/* if there are no file descriptors being waited on and no
|
||||||
timeout set, this is clearly ridiculous, so stop the run */
|
timeout set, this is clearly ridiculous, so stop the run */
|
||||||
|
assert(ptv || n_read_fds);
|
||||||
if (!ptv && (n_read_fds == 0)) {
|
|
||||||
LOG_FATAL(LOGF_Scheduler, "No descriptors or timeout to wait for");
|
|
||||||
}
|
|
||||||
|
|
||||||
status = select(one_highest_fd, &rd, NULL, NULL, ptv);
|
status = select(one_highest_fd, &rd, NULL, NULL, ptv);
|
||||||
|
|
||||||
@@ -616,8 +613,6 @@ SCH_MainLoop(void)
|
|||||||
dispatch_filehandlers(status, &rd);
|
dispatch_filehandlers(status, &rd);
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
assert(status == 0);
|
|
||||||
|
|
||||||
/* No descriptors readable, timeout must have elapsed.
|
/* No descriptors readable, timeout must have elapsed.
|
||||||
Therefore, tv must be non-null */
|
Therefore, tv must be non-null */
|
||||||
assert(ptv);
|
assert(ptv);
|
||||||
|
|||||||
Reference in New Issue
Block a user