summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/proto.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/proto.c b/src/proto.c
index cbf50d1..ed23112 100644
--- a/src/proto.c
+++ b/src/proto.c
@@ -291,7 +291,11 @@ PROCESS_REPONSE(lookup_response) {
fatal("Response too short");
}
- assert(cont->lookup->state == OP_ACTIVE);
+ if(cont->lookup->state != OP_ACTIVE) {
+ // The lookup is not running so we have nowhere to dump the result.
+ // Just discard the packet
+ return PROTO_EDISC;
+ }
struct nodeid id;
uint8_t nodes_len;