Skip to content

Commit 210f50d

Browse files
author
Paul Thompson
committed
Flip order of comparison
1 parent 712b47f commit 210f50d

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

events/equeue/equeue.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ static inline int equeue_clampdiff(unsigned a, unsigned b) {
3737
// Increment the unique id in an event, hiding the event from cancel
3838
static inline void equeue_incid(equeue_t *q, struct equeue_event *e) {
3939
e->id += 1;
40-
if (0 == (e->id << q->npw2)) {
40+
if ((e->id << q->npw2) == 0) {
4141
e->id = 1;
4242
}
4343
}
@@ -469,7 +469,7 @@ void equeue_event_dtor(void *p, void (*dtor)(void *)) {
469469
}
470470

471471

472-
// simple callbacks
472+
// simple callbacks
473473
struct ecallback {
474474
void (*cb)(void*);
475475
void *data;

0 commit comments

Comments
 (0)