diff options
author | Christian Grothoff <christian@grothoff.org> | 2016-06-19 22:45:09 +0000 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2016-06-19 22:45:09 +0000 |
commit | 42f625fe75fce04175965b12d1edb809b56433af (patch) | |
tree | c3dd1ad8de1d2db58fe18fd0c16a3cef3765ef73 /src/scalarproduct/gnunet-service-scalarproduct_alice.c | |
parent | 9a0a4efca26978f8e01513dfa291747e24907e3f (diff) | |
download | gnunet-42f625fe75fce04175965b12d1edb809b56433af.tar.gz gnunet-42f625fe75fce04175965b12d1edb809b56433af.zip |
avoid assertion on NULL mq
Diffstat (limited to 'src/scalarproduct/gnunet-service-scalarproduct_alice.c')
-rw-r--r-- | src/scalarproduct/gnunet-service-scalarproduct_alice.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/scalarproduct/gnunet-service-scalarproduct_alice.c b/src/scalarproduct/gnunet-service-scalarproduct_alice.c index 7eb2d006c..d6da754f4 100644 --- a/src/scalarproduct/gnunet-service-scalarproduct_alice.c +++ b/src/scalarproduct/gnunet-service-scalarproduct_alice.c | |||
@@ -447,18 +447,18 @@ cb_channel_destruction (void *cls, | |||
447 | "Peer disconnected, terminating session %s with peer %s\n", | 447 | "Peer disconnected, terminating session %s with peer %s\n", |
448 | GNUNET_h2s (&s->session_id), | 448 | GNUNET_h2s (&s->session_id), |
449 | GNUNET_i2s (&s->peer)); | 449 | GNUNET_i2s (&s->peer)); |
450 | if (NULL != s->cadet_mq) | ||
451 | { | ||
452 | GNUNET_MQ_destroy (s->cadet_mq); | ||
453 | s->cadet_mq = NULL; | ||
454 | } | ||
455 | s->channel = NULL; | ||
456 | if (GNUNET_SCALARPRODUCT_STATUS_ACTIVE == s->status) | 450 | if (GNUNET_SCALARPRODUCT_STATUS_ACTIVE == s->status) |
457 | { | 451 | { |
458 | /* We didn't get an answer yet, fail with error */ | 452 | /* We didn't get an answer yet, fail with error */ |
459 | s->status = GNUNET_SCALARPRODUCT_STATUS_FAILURE; | 453 | s->status = GNUNET_SCALARPRODUCT_STATUS_FAILURE; |
460 | prepare_client_end_notification (s); | 454 | prepare_client_end_notification (s); |
461 | } | 455 | } |
456 | if (NULL != s->cadet_mq) | ||
457 | { | ||
458 | GNUNET_MQ_destroy (s->cadet_mq); | ||
459 | s->cadet_mq = NULL; | ||
460 | } | ||
461 | s->channel = NULL; | ||
462 | } | 462 | } |
463 | 463 | ||
464 | 464 | ||