diff options
Diffstat (limited to 'src/dht/gnunet-dht-get-peer.c')
-rw-r--r-- | src/dht/gnunet-dht-get-peer.c | 17 |
1 files changed, 6 insertions, 11 deletions
diff --git a/src/dht/gnunet-dht-get-peer.c b/src/dht/gnunet-dht-get-peer.c index 6ca88d232..2de7e93be 100644 --- a/src/dht/gnunet-dht-get-peer.c +++ b/src/dht/gnunet-dht-get-peer.c | |||
@@ -126,9 +126,8 @@ find_peer_processor (void *cls, const struct GNUNET_HELLO_Message *hello) | |||
126 | * @param c configuration | 126 | * @param c configuration |
127 | */ | 127 | */ |
128 | static void | 128 | static void |
129 | run (void *cls, | 129 | run (void *cls, char *const *args, const char *cfgfile, |
130 | char *const *args, | 130 | const struct GNUNET_CONFIGURATION_Handle *c) |
131 | const char *cfgfile, const struct GNUNET_CONFIGURATION_Handle *c) | ||
132 | { | 131 | { |
133 | struct GNUNET_TIME_Relative timeout; | 132 | struct GNUNET_TIME_Relative timeout; |
134 | GNUNET_HashCode key; | 133 | GNUNET_HashCode key; |
@@ -164,11 +163,9 @@ run (void *cls, | |||
164 | if (verbose) | 163 | if (verbose) |
165 | fprintf (stderr, "Issuing FIND PEER request for %s!\n", query_key); | 164 | fprintf (stderr, "Issuing FIND PEER request for %s!\n", query_key); |
166 | 165 | ||
167 | find_peer_handle = GNUNET_DHT_find_peer_start (dht_handle, | 166 | find_peer_handle = |
168 | timeout, | 167 | GNUNET_DHT_find_peer_start (dht_handle, timeout, &key, GNUNET_DHT_RO_NONE, |
169 | &key, | 168 | &find_peer_processor, NULL); |
170 | GNUNET_DHT_RO_NONE, | ||
171 | &find_peer_processor, NULL); | ||
172 | if (NULL == find_peer_handle) | 169 | if (NULL == find_peer_handle) |
173 | { | 170 | { |
174 | GNUNET_SCHEDULER_add_now (&shutdown_task, NULL); | 171 | GNUNET_SCHEDULER_add_now (&shutdown_task, NULL); |
@@ -207,9 +204,7 @@ int | |||
207 | main (int argc, char *const *argv) | 204 | main (int argc, char *const *argv) |
208 | { | 205 | { |
209 | return (GNUNET_OK == | 206 | return (GNUNET_OK == |
210 | GNUNET_PROGRAM_run (argc, | 207 | GNUNET_PROGRAM_run (argc, argv, "gnunet-dht-get-peer", |
211 | argv, | ||
212 | "gnunet-dht-get-peer", | ||
213 | gettext_noop | 208 | gettext_noop |
214 | ("Issue a GET PEER request to the GNUnet DHT, print results."), | 209 | ("Issue a GET PEER request to the GNUnet DHT, print results."), |
215 | options, &run, NULL)) ? ret : 1; | 210 | options, &run, NULL)) ? ret : 1; |