diff options
author | Christian Grothoff <christian@grothoff.org> | 2013-10-17 09:30:02 +0000 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2013-10-17 09:30:02 +0000 |
commit | ebfdd8ee795b77891b51f25cc86c3a5f55d08851 (patch) | |
tree | c9843c14fa7bcd1c907f17f275429c1983dc315e /src/namestore/test_namestore_api_remove_not_existing_record.c | |
parent | 058ac097acf6b4ea0f856746469beb5a16bd3b4a (diff) | |
download | gnunet-ebfdd8ee795b77891b51f25cc86c3a5f55d08851.tar.gz gnunet-ebfdd8ee795b77891b51f25cc86c3a5f55d08851.zip |
-indentation, code cleanup
Diffstat (limited to 'src/namestore/test_namestore_api_remove_not_existing_record.c')
-rw-r--r-- | src/namestore/test_namestore_api_remove_not_existing_record.c | 31 |
1 files changed, 14 insertions, 17 deletions
diff --git a/src/namestore/test_namestore_api_remove_not_existing_record.c b/src/namestore/test_namestore_api_remove_not_existing_record.c index 059243695..0e7cc6b33 100644 --- a/src/namestore/test_namestore_api_remove_not_existing_record.c +++ b/src/namestore/test_namestore_api_remove_not_existing_record.c | |||
@@ -1,6 +1,6 @@ | |||
1 | /* | 1 | /* |
2 | This file is part of GNUnet. | 2 | This file is part of GNUnet. |
3 | (C) 2009 Christian Grothoff (and other contributing authors) | 3 | (C) 2013 Christian Grothoff (and other contributing authors) |
4 | 4 | ||
5 | GNUnet is free software; you can redistribute it and/or modify | 5 | GNUnet is free software; you can redistribute it and/or modify |
6 | it under the terms of the GNU General Public License as published | 6 | it under the terms of the GNU General Public License as published |
@@ -84,7 +84,8 @@ endbadly (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | |||
84 | 84 | ||
85 | 85 | ||
86 | static void | 86 | static void |
87 | end (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | 87 | end (void *cls, |
88 | const struct GNUNET_SCHEDULER_TaskContext *tc) | ||
88 | { | 89 | { |
89 | cleanup (); | 90 | cleanup (); |
90 | res = 0; | 91 | res = 0; |
@@ -95,40 +96,36 @@ static void | |||
95 | put_cont (void *cls, int32_t success, const char *emsg) | 96 | put_cont (void *cls, int32_t success, const char *emsg) |
96 | { | 97 | { |
97 | GNUNET_assert (NULL != cls); | 98 | GNUNET_assert (NULL != cls); |
98 | |||
99 | nsqe = NULL; | 99 | nsqe = NULL; |
100 | |||
101 | if (GNUNET_SYSERR == success) | 100 | if (GNUNET_SYSERR == success) |
102 | { | 101 | { |
103 | GNUNET_break (0); | 102 | GNUNET_break (0); |
104 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, | 103 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, |
105 | _("Namestore could not remove record: `%s'\n"), emsg); | 104 | "Namestore could not remove record: `%s'\n", |
106 | if (endbadly_task != GNUNET_SCHEDULER_NO_TASK) | 105 | emsg); |
107 | GNUNET_SCHEDULER_cancel (endbadly_task); | 106 | GNUNET_SCHEDULER_shutdown (); |
108 | endbadly_task = GNUNET_SCHEDULER_add_now (&endbadly, NULL); | ||
109 | return; | 107 | return; |
110 | } | 108 | } |
111 | else if (GNUNET_OK == success) | 109 | else if (GNUNET_OK == success) |
112 | { | 110 | { |
113 | GNUNET_break (0); | 111 | GNUNET_break (0); |
114 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, | 112 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, |
115 | _("Namestore did remove not exisiting record: `%s'\n"), emsg); | 113 | "Namestore did remove not exisiting record: `%s'\n", |
116 | if (endbadly_task != GNUNET_SCHEDULER_NO_TASK) | 114 | emsg); |
117 | GNUNET_SCHEDULER_cancel (endbadly_task); | 115 | GNUNET_SCHEDULER_shutdown (); |
118 | endbadly_task = GNUNET_SCHEDULER_add_now (&endbadly, NULL); | ||
119 | return; | 116 | return; |
120 | } | 117 | } |
121 | else | 118 | else |
122 | { | 119 | { |
123 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 120 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
124 | "Name was not removed\n"); | 121 | "Name was not removed\n"); |
125 | res = 0; | 122 | res = 0; |
126 | if (endbadly_task != GNUNET_SCHEDULER_NO_TASK) | 123 | if (endbadly_task != GNUNET_SCHEDULER_NO_TASK) |
127 | { | 124 | { |
128 | GNUNET_SCHEDULER_cancel (endbadly_task); | 125 | GNUNET_SCHEDULER_cancel (endbadly_task); |
129 | endbadly_task = GNUNET_SCHEDULER_NO_TASK; | 126 | endbadly_task = GNUNET_SCHEDULER_NO_TASK; |
130 | } | 127 | } |
131 | GNUNET_SCHEDULER_add_now (&end, NULL); | 128 | GNUNET_SCHEDULER_add_now (&end, NULL); |
132 | } | 129 | } |
133 | } | 130 | } |
134 | 131 | ||