aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2018-01-13 14:35:06 +0100
committerChristian Grothoff <christian@grothoff.org>2018-01-13 14:35:06 +0100
commit7c2ee1630fd348e1a0c1db6508cc5d2d16452acf (patch)
treecaafb15ed6ccac6ca2e60e67fb7d05f7ce2c8bb0
parent88a4bbdd9857746e2ffdd9028b091c2be0bd3fe7 (diff)
downloadgnunet-7c2ee1630fd348e1a0c1db6508cc5d2d16452acf.tar.gz
gnunet-7c2ee1630fd348e1a0c1db6508cc5d2d16452acf.zip
prevent NPE
-rw-r--r--src/transport/gnunet-service-transport_neighbours.c2
-rw-r--r--src/util/container_bloomfilter.c2
2 files changed, 3 insertions, 1 deletions
diff --git a/src/transport/gnunet-service-transport_neighbours.c b/src/transport/gnunet-service-transport_neighbours.c
index 2bf07bcd7..e6e4de0f5 100644
--- a/src/transport/gnunet-service-transport_neighbours.c
+++ b/src/transport/gnunet-service-transport_neighbours.c
@@ -2137,6 +2137,8 @@ inbound_bw_tracker_update (void *cls)
2137 "New inbound delay for peer `%s' is %llu ms\n", 2137 "New inbound delay for peer `%s' is %llu ms\n",
2138 GNUNET_i2s (&n->id), 2138 GNUNET_i2s (&n->id),
2139 (unsigned long long) delay.rel_value_us / 1000LL); 2139 (unsigned long long) delay.rel_value_us / 1000LL);
2140 if (NULL == n->primary_address.session)
2141 return;
2140 papi->update_inbound_delay (papi->cls, 2142 papi->update_inbound_delay (papi->cls,
2141 &n->id, 2143 &n->id,
2142 n->primary_address.session, 2144 n->primary_address.session,
diff --git a/src/util/container_bloomfilter.c b/src/util/container_bloomfilter.c
index 95c05b9d7..db61c5221 100644
--- a/src/util/container_bloomfilter.c
+++ b/src/util/container_bloomfilter.c
@@ -660,7 +660,7 @@ GNUNET_CONTAINER_bloomfilter_init (const char *data, size_t size,
660 * @param bf bloomfilter to take the raw data from 660 * @param bf bloomfilter to take the raw data from
661 * @param data where to write the data 661 * @param data where to write the data
662 * @param size the size of the given data array 662 * @param size the size of the given data array
663 * @return GNUNET_SYSERR if the data array is not big enough 663 * @return #GNUNET_SYSERR if the data array is not big enough
664 */ 664 */
665int 665int
666GNUNET_CONTAINER_bloomfilter_get_raw_data (const struct 666GNUNET_CONTAINER_bloomfilter_get_raw_data (const struct