diff --git a/chronos/asyncloop.nim b/chronos/asyncloop.nim index d48f9dc..b72553e 100644 --- a/chronos/asyncloop.nim +++ b/chronos/asyncloop.nim @@ -823,7 +823,7 @@ proc withTimeout*[T](fut: Future[T], timeout: Duration): Future[bool] = if not(retFuture.finished()): if isNil(udata): # Timer exceeded first. - clearTimer(timer) + fut.removeCallback(continuation) fut.cancel() retFuture.complete(false) else: