sd-event: fix delays assert brain-o (#17790)
s/sizeof/ELEMENTSOF/
Bug introduced in 34b8751774
.
This commit is contained in:
parent
e11ec61d65
commit
cb9d621ebb
|
@ -3725,7 +3725,7 @@ _public_ int sd_event_run(sd_event *e, uint64_t timeout) {
|
||||||
this_run = now(CLOCK_MONOTONIC);
|
this_run = now(CLOCK_MONOTONIC);
|
||||||
|
|
||||||
l = u64log2(this_run - e->last_run);
|
l = u64log2(this_run - e->last_run);
|
||||||
assert(l < sizeof(e->delays));
|
assert(l < ELEMENTSOF(e->delays));
|
||||||
e->delays[l]++;
|
e->delays[l]++;
|
||||||
|
|
||||||
if (this_run - e->last_log >= 5*USEC_PER_SEC) {
|
if (this_run - e->last_log >= 5*USEC_PER_SEC) {
|
||||||
|
|
Loading…
Reference in New Issue