diff options
Diffstat (limited to 'src/cadet/gnunet-service-cadet_hello.c')
-rw-r--r-- | src/cadet/gnunet-service-cadet_hello.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/src/cadet/gnunet-service-cadet_hello.c b/src/cadet/gnunet-service-cadet_hello.c index 9229483fe..19b45c9cd 100644 --- a/src/cadet/gnunet-service-cadet_hello.c +++ b/src/cadet/gnunet-service-cadet_hello.c | |||
@@ -108,7 +108,7 @@ got_hello (void *cls, const struct GNUNET_PeerIdentity *id, | |||
108 | LOG (GNUNET_ERROR_TYPE_DEBUG, " hello for %s (%d bytes), expires on %s\n", | 108 | LOG (GNUNET_ERROR_TYPE_DEBUG, " hello for %s (%d bytes), expires on %s\n", |
109 | GNUNET_i2s (id), GNUNET_HELLO_size (hello), | 109 | GNUNET_i2s (id), GNUNET_HELLO_size (hello), |
110 | GNUNET_STRINGS_absolute_time_to_string (GNUNET_HELLO_get_last_expiration(hello))); | 110 | GNUNET_STRINGS_absolute_time_to_string (GNUNET_HELLO_get_last_expiration(hello))); |
111 | peer = GCP_get (id); | 111 | peer = GCP_get (id, GNUNET_YES); |
112 | GCP_set_hello (peer, hello); | 112 | GCP_set_hello (peer, hello); |
113 | 113 | ||
114 | if (GCP_get_short_id (peer) == myid) | 114 | if (GCP_get_short_id (peer) == myid) |
@@ -176,7 +176,12 @@ GCH_get_mine (void) | |||
176 | const struct GNUNET_HELLO_Message * | 176 | const struct GNUNET_HELLO_Message * |
177 | GCH_get (const struct GNUNET_PeerIdentity *id) | 177 | GCH_get (const struct GNUNET_PeerIdentity *id) |
178 | { | 178 | { |
179 | return GCP_get_hello (GCP_get (id)); | 179 | struct CadetPeer *p; |
180 | |||
181 | p = GCP_get (id, GNUNET_NO); | ||
182 | if (NULL == p) | ||
183 | return NULL; | ||
184 | return GCP_get_hello (p); | ||
180 | } | 185 | } |
181 | 186 | ||
182 | 187 | ||