summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDimitri Staessens <[email protected]>2022-02-25 00:15:30 +0100
committerSander Vrijders <[email protected]>2022-03-03 12:00:54 +0100
commitb3810b664aa3422d0c69c8fcf713c24d7bf16c26 (patch)
tree4e04fcf6085035a7091ef6e17b43c75b6a61a9df
parent3330f7f22105e3a8b57f5c562144d8c3e338e156 (diff)
downloadouroboros-b3810b664aa3422d0c69c8fcf713c24d7bf16c26.tar.gz
ouroboros-b3810b664aa3422d0c69c8fcf713c24d7bf16c26.zip
lib: Remove dead code in timerwheel
The checked condition can't happen. Signed-off-by: Dimitri Staessens <[email protected]> Signed-off-by: Sander Vrijders <[email protected]>
-rw-r--r--src/lib/timerwheel.c6
1 files changed, 0 insertions, 6 deletions
diff --git a/src/lib/timerwheel.c b/src/lib/timerwheel.c
index 487dcd0e..5c0fbfa0 100644
--- a/src/lib/timerwheel.c
+++ b/src/lib/timerwheel.c
@@ -395,12 +395,6 @@ static int timerwheel_ack(int fd,
clock_gettime(PTHREAD_COND_CLOCK, &now);
- slot = DELT_ACK >> ACKQ_RES;
- if (slot >= ACKQ_SLOTS) { /* Out of timerwheel range. */
- free(a);
- return -EPERM;
- }
-
slot = (((ts_to_ns(now) + DELT_ACK) >> ACKQ_RES) + 1)
& (ACKQ_SLOTS - 1);