diff options
author | Christian Grothoff <christian@grothoff.org> | 2013-11-28 19:38:30 +0000 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2013-11-28 19:38:30 +0000 |
commit | ce30893f17420b6db33927575a324d0e9f3ea6de (patch) | |
tree | bf8cf034eaa77e80a2138b3de2b8db4df88031fe /src/peerinfo/gnunet-service-peerinfo.c | |
parent | d3466b95673b3afc5d1d8a2a018bc160c561c389 (diff) | |
download | gnunet-ce30893f17420b6db33927575a324d0e9f3ea6de.tar.gz gnunet-ce30893f17420b6db33927575a324d0e9f3ea6de.zip |
-check return value
Diffstat (limited to 'src/peerinfo/gnunet-service-peerinfo.c')
-rw-r--r-- | src/peerinfo/gnunet-service-peerinfo.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/peerinfo/gnunet-service-peerinfo.c b/src/peerinfo/gnunet-service-peerinfo.c index fe5094d79..2f1e7a3d9 100644 --- a/src/peerinfo/gnunet-service-peerinfo.c +++ b/src/peerinfo/gnunet-service-peerinfo.c | |||
@@ -446,10 +446,11 @@ add_host_to_known_hosts (const struct GNUNET_PeerIdentity *identity) | |||
446 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Adding new peer `%s'\n", GNUNET_i2s (identity)); | 446 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Adding new peer `%s'\n", GNUNET_i2s (identity)); |
447 | GNUNET_STATISTICS_update (stats, gettext_noop ("# peers known"), 1, | 447 | GNUNET_STATISTICS_update (stats, gettext_noop ("# peers known"), 1, |
448 | GNUNET_NO); | 448 | GNUNET_NO); |
449 | entry = GNUNET_malloc (sizeof (struct HostEntry)); | 449 | entry = GNUNET_new (struct HostEntry); |
450 | entry->identity = *identity; | 450 | entry->identity = *identity; |
451 | GNUNET_CONTAINER_multipeermap_put (hostmap, &entry->identity, entry, | 451 | GNUNET_assert (GNUNET_OK == |
452 | GNUNET_CONTAINER_MULTIHASHMAPOPTION_UNIQUE_ONLY); | 452 | GNUNET_CONTAINER_multipeermap_put (hostmap, &entry->identity, entry, |
453 | GNUNET_CONTAINER_MULTIHASHMAPOPTION_UNIQUE_ONLY)); | ||
453 | notify_all (entry); | 454 | notify_all (entry); |
454 | fn = get_host_filename (identity); | 455 | fn = get_host_filename (identity); |
455 | if (NULL != fn) | 456 | if (NULL != fn) |