aboutsummaryrefslogtreecommitdiff
path: root/src/dht/gnunet-dht-put.c
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2016-04-30 08:17:37 +0000
committerChristian Grothoff <christian@grothoff.org>2016-04-30 08:17:37 +0000
commit95f9076a2139f5fb042b944a0658b6cda2fa35db (patch)
treeb0826a2a1dcf812e6b4450fe6b05d47cd53ae49d /src/dht/gnunet-dht-put.c
parent7746f68db77b9ca3c4aaca24ab2ce5253461240b (diff)
downloadgnunet-95f9076a2139f5fb042b944a0658b6cda2fa35db.tar.gz
gnunet-95f9076a2139f5fb042b944a0658b6cda2fa35db.zip
implementing new scheduler shutdown semantics
Diffstat (limited to 'src/dht/gnunet-dht-put.c')
-rw-r--r--src/dht/gnunet-dht-put.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/dht/gnunet-dht-put.c b/src/dht/gnunet-dht-put.c
index 19e385be1..972369e10 100644
--- a/src/dht/gnunet-dht-put.c
+++ b/src/dht/gnunet-dht-put.c
@@ -98,6 +98,7 @@ shutdown_task (void *cls)
98 } 98 }
99} 99}
100 100
101
101/** 102/**
102 * Signature of the main function of a task. 103 * Signature of the main function of a task.
103 * 104 *
@@ -132,6 +133,7 @@ message_sent_cont (void *cls, int success)
132 GNUNET_SCHEDULER_add_now (&shutdown_task, NULL); 133 GNUNET_SCHEDULER_add_now (&shutdown_task, NULL);
133} 134}
134 135
136
135/** 137/**
136 * Main function that will be run by the scheduler. 138 * Main function that will be run by the scheduler.
137 * 139 *
@@ -141,14 +143,15 @@ message_sent_cont (void *cls, int success)
141 * @param c configuration 143 * @param c configuration
142 */ 144 */
143static void 145static void
144run (void *cls, char *const *args, const char *cfgfile, 146run (void *cls,
147 char *const *args,
148 const char *cfgfile,
145 const struct GNUNET_CONFIGURATION_Handle *c) 149 const struct GNUNET_CONFIGURATION_Handle *c)
146{ 150{
147 struct GNUNET_TIME_Relative timeout; 151 struct GNUNET_TIME_Relative timeout;
148 struct GNUNET_TIME_Absolute expiration; 152 struct GNUNET_TIME_Absolute expiration;
149 153
150 cfg = c; 154 cfg = c;
151
152 if ((NULL == query_key) || (NULL == data)) 155 if ((NULL == query_key) || (NULL == data))
153 { 156 {
154 FPRINTF (stderr, "%s", _("Must provide KEY and DATA for DHT put!\n")); 157 FPRINTF (stderr, "%s", _("Must provide KEY and DATA for DHT put!\n"));