diff options
author | Sree Harsha Totakura <totakura@in.tum.de> | 2012-07-17 19:09:02 +0000 |
---|---|---|
committer | Sree Harsha Totakura <totakura@in.tum.de> | 2012-07-17 19:09:02 +0000 |
commit | 89daff335a418fb67ce8ea4d3e1e128e96d19877 (patch) | |
tree | 3438c43bd31ef7ffa7827552f56bee52cba80d45 | |
parent | 9761f2065f0ed797d0133388b94ee8e169ab6013 (diff) | |
download | gnunet-89daff335a418fb67ce8ea4d3e1e128e96d19877.tar.gz gnunet-89daff335a418fb67ce8ea4d3e1e128e96d19877.zip |
helper exception callback lesser parameters
-rw-r--r-- | src/include/gnunet_helper_lib.h | 6 | ||||
-rw-r--r-- | src/testbed/test_testbed_api_hosts.c | 5 | ||||
-rw-r--r-- | src/testbed/testbed_api.c | 5 | ||||
-rw-r--r-- | src/testbed/testbed_api_hosts.c | 7 | ||||
-rw-r--r-- | src/util/helper.c | 6 |
5 files changed, 8 insertions, 21 deletions
diff --git a/src/include/gnunet_helper_lib.h b/src/include/gnunet_helper_lib.h index 2756cdf4e..12a4d3fe1 100644 --- a/src/include/gnunet_helper_lib.h +++ b/src/include/gnunet_helper_lib.h | |||
@@ -42,12 +42,8 @@ struct GNUNET_HELPER_Handle; | |||
42 | * when the helper process is stoped using GNUNET_HELPER_stop() | 42 | * when the helper process is stoped using GNUNET_HELPER_stop() |
43 | * | 43 | * |
44 | * @param cls the closure from GNUNET_HELPER_start() | 44 | * @param cls the closure from GNUNET_HELPER_start() |
45 | * @param h the handle representing the helper process. This handle is invalid | ||
46 | * in this callback. It is only presented for reference. No operations | ||
47 | * can be performed using it. | ||
48 | */ | 45 | */ |
49 | typedef void (*GNUNET_HELPER_ExceptionCallback) (void *cls, | 46 | typedef void (*GNUNET_HELPER_ExceptionCallback) (void *cls); |
50 | const struct GNUNET_HELPER_Handle *h); | ||
51 | 47 | ||
52 | 48 | ||
53 | /** | 49 | /** |
diff --git a/src/testbed/test_testbed_api_hosts.c b/src/testbed/test_testbed_api_hosts.c index add3a1e02..54e2461c7 100644 --- a/src/testbed/test_testbed_api_hosts.c +++ b/src/testbed/test_testbed_api_hosts.c | |||
@@ -72,12 +72,9 @@ do_shutdown (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | |||
72 | * when the helper process is stoped using GNUNET_HELPER_stop() | 72 | * when the helper process is stoped using GNUNET_HELPER_stop() |
73 | * | 73 | * |
74 | * @param cls the closure from GNUNET_HELPER_start() | 74 | * @param cls the closure from GNUNET_HELPER_start() |
75 | * @param h the handle representing the helper process. This handle is invalid | ||
76 | * in this callback. It is only presented for reference. No operations | ||
77 | * can be performed using it. | ||
78 | */ | 75 | */ |
79 | static void | 76 | static void |
80 | exp_cb (void *cls, const struct GNUNET_HELPER_Handle *h) | 77 | exp_cb (void *cls) |
81 | { | 78 | { |
82 | status = GNUNET_SYSERR; | 79 | status = GNUNET_SYSERR; |
83 | GNUNET_SCHEDULER_cancel (shutdown_id); | 80 | GNUNET_SCHEDULER_cancel (shutdown_id); |
diff --git a/src/testbed/testbed_api.c b/src/testbed/testbed_api.c index 7c4436003..aa410e010 100644 --- a/src/testbed/testbed_api.c +++ b/src/testbed/testbed_api.c | |||
@@ -447,12 +447,9 @@ struct GNUNET_TESTBED_ControllerProc | |||
447 | * when the helper process is stoped using GNUNET_HELPER_stop() | 447 | * when the helper process is stoped using GNUNET_HELPER_stop() |
448 | * | 448 | * |
449 | * @param cls the closure from GNUNET_HELPER_start() | 449 | * @param cls the closure from GNUNET_HELPER_start() |
450 | * @param h the handle representing the helper process. This handle is invalid | ||
451 | * in this callback. It is only presented for reference. No operations | ||
452 | * can be performed using it. | ||
453 | */ | 450 | */ |
454 | static void | 451 | static void |
455 | controller_exp_cb (void *cls, const struct GNUNET_HELPER_Handle *h) | 452 | controller_exp_cb (void *cls) |
456 | { | 453 | { |
457 | struct GNUNET_TESTBED_ControllerProc *cproc = cls; | 454 | struct GNUNET_TESTBED_ControllerProc *cproc = cls; |
458 | 455 | ||
diff --git a/src/testbed/testbed_api_hosts.c b/src/testbed/testbed_api_hosts.c index 5fe525b9e..f88da52b8 100644 --- a/src/testbed/testbed_api_hosts.c +++ b/src/testbed/testbed_api_hosts.c | |||
@@ -357,18 +357,15 @@ clear_msg (void *cls, int result) | |||
357 | * when the helper process is stoped using GNUNET_HELPER_stop() | 357 | * when the helper process is stoped using GNUNET_HELPER_stop() |
358 | * | 358 | * |
359 | * @param cls the closure from GNUNET_HELPER_start() | 359 | * @param cls the closure from GNUNET_HELPER_start() |
360 | * @param h the handle representing the helper process. This handle is invalid | ||
361 | * in this callback. It is only presented for reference. No operations | ||
362 | * can be performed using it. | ||
363 | */ | 360 | */ |
364 | static void | 361 | static void |
365 | helper_exp_cb (void *cls, const struct GNUNET_HELPER_Handle *h) | 362 | helper_exp_cb (void *cls) |
366 | { | 363 | { |
367 | struct GNUNET_TESTBED_HelperHandle *handle = cls; | 364 | struct GNUNET_TESTBED_HelperHandle *handle = cls; |
368 | 365 | ||
369 | handle->is_stopped = GNUNET_YES; | 366 | handle->is_stopped = GNUNET_YES; |
370 | GNUNET_TESTBED_host_stop_ (handle); | 367 | GNUNET_TESTBED_host_stop_ (handle); |
371 | handle->exp_cb (handle->exp_cb_cls, h); | 368 | handle->exp_cb (handle->exp_cb_cls); |
372 | } | 369 | } |
373 | 370 | ||
374 | 371 | ||
diff --git a/src/util/helper.c b/src/util/helper.c index 3fe3705b1..82b94aa2f 100644 --- a/src/util/helper.c +++ b/src/util/helper.c | |||
@@ -256,7 +256,7 @@ helper_read (void *cls, | |||
256 | STRERROR (errno)); | 256 | STRERROR (errno)); |
257 | if (NULL != h->exp_cb) | 257 | if (NULL != h->exp_cb) |
258 | { | 258 | { |
259 | h->exp_cb (h->cb_cls, h); | 259 | h->exp_cb (h->cb_cls); |
260 | GNUNET_HELPER_stop (h); | 260 | GNUNET_HELPER_stop (h); |
261 | return; | 261 | return; |
262 | } | 262 | } |
@@ -275,7 +275,7 @@ helper_read (void *cls, | |||
275 | h->binary_name); | 275 | h->binary_name); |
276 | if (NULL != h->exp_cb) | 276 | if (NULL != h->exp_cb) |
277 | { | 277 | { |
278 | h->exp_cb (h->cb_cls, h); | 278 | h->exp_cb (h->cb_cls); |
279 | GNUNET_HELPER_stop (h); | 279 | GNUNET_HELPER_stop (h); |
280 | return; | 280 | return; |
281 | } | 281 | } |
@@ -300,7 +300,7 @@ helper_read (void *cls, | |||
300 | h->binary_name); | 300 | h->binary_name); |
301 | if (NULL != h->exp_cb) | 301 | if (NULL != h->exp_cb) |
302 | { | 302 | { |
303 | h->exp_cb (h->cb_cls, h); | 303 | h->exp_cb (h->cb_cls); |
304 | GNUNET_HELPER_stop (h); | 304 | GNUNET_HELPER_stop (h); |
305 | return; | 305 | return; |
306 | } | 306 | } |