fix crash when can't find a CID and timeout hits
the exception was not raised, thus a Nil was returned that was than wrapped in an option, leading to crash. Signed-off-by: Csaba Kiraly <csaba.kiraly@gmail.com>
This commit is contained in:
parent
f235cc6621
commit
0bd2fabaa4
|
@ -48,6 +48,8 @@ proc getWantHandle*(
|
|||
raise exc
|
||||
except CatchableError as exc:
|
||||
trace "Pending WANT failed or expired", exc = exc.msg
|
||||
# no need to cancel, it is already cancelled by wait()
|
||||
raise exc
|
||||
finally:
|
||||
p.blocks.del(cid)
|
||||
|
||||
|
|
Loading…
Reference in New Issue