projects
/
oweals
/
gnunet.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
ed1c91f
)
fix potential NPE
author
Christian Grothoff
<christian@grothoff.org>
Sun, 8 Jan 2017 19:09:59 +0000
(20:09 +0100)
committer
Christian Grothoff
<christian@grothoff.org>
Sun, 8 Jan 2017 19:09:59 +0000
(20:09 +0100)
src/nat/nat_api.c
patch
|
blob
|
history
diff --git
a/src/nat/nat_api.c
b/src/nat/nat_api.c
index 826dbd57a33c09f37ff68ab9e13ebff8a491c006..5b4c39682b09b647f3a2d794c751cdf34a8145a2 100644
(file)
--- a/
src/nat/nat_api.c
+++ b/
src/nat/nat_api.c
@@
-709,7
+709,11
@@
GNUNET_NAT_request_reversal (struct GNUNET_NAT_Handle *nh,
void
GNUNET_NAT_unregister (struct GNUNET_NAT_Handle *nh)
{
- GNUNET_MQ_destroy (nh->mq);
+ if (NULL != nh->mq)
+ {
+ GNUNET_MQ_destroy (nh->mq);
+ nh->mq = NULL;
+ }
GNUNET_free (nh->reg);
GNUNET_free (nh);
}