aboutsummaryrefslogtreecommitdiff
path: root/src/namestore/test_namestore_api_monitoring.c
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2013-10-20 18:04:56 +0000
committerChristian Grothoff <christian@grothoff.org>2013-10-20 18:04:56 +0000
commit084f7e3620774cf976ef955a3db5df9ff7651263 (patch)
treea242630dd83574f1bcff6c825c16da987d5eef0b /src/namestore/test_namestore_api_monitoring.c
parent0380fddde67fd46e9e5a201121f3c38ba15f6ccd (diff)
downloadgnunet-084f7e3620774cf976ef955a3db5df9ff7651263.tar.gz
gnunet-084f7e3620774cf976ef955a3db5df9ff7651263.zip
-32 bit, not 16
Diffstat (limited to 'src/namestore/test_namestore_api_monitoring.c')
-rw-r--r--src/namestore/test_namestore_api_monitoring.c27
1 files changed, 17 insertions, 10 deletions
diff --git a/src/namestore/test_namestore_api_monitoring.c b/src/namestore/test_namestore_api_monitoring.c
index c9b182fc8..a0a5ec4b6 100644
--- a/src/namestore/test_namestore_api_monitoring.c
+++ b/src/namestore/test_namestore_api_monitoring.c
@@ -150,13 +150,15 @@ zone_proc (void *cls,
150 unsigned int rd_count, 150 unsigned int rd_count,
151 const struct GNUNET_GNSRECORD_Data *rd) 151 const struct GNUNET_GNSRECORD_Data *rd)
152{ 152{
153 static int returned_records; 153 static int returned_records;
154 static int fail = GNUNET_NO; 154 static int fail = GNUNET_NO;
155
155 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, 156 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
156 "Comparing results name %s\n", 157 "Comparing results name %s\n",
157 name); 158 name);
158 159 if (0 != memcmp (zone_key,
159 if (0 != memcmp (zone_key, privkey, sizeof (struct GNUNET_CRYPTO_EcdsaPrivateKey))) 160 privkey,
161 sizeof (struct GNUNET_CRYPTO_EcdsaPrivateKey)))
160 { 162 {
161 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, 163 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
162 "Monitoring returned wrong zone key\n"); 164 "Monitoring returned wrong zone key\n");
@@ -185,8 +187,9 @@ zone_proc (void *cls,
185 else 187 else
186 { 188 {
187 GNUNET_log (GNUNET_ERROR_TYPE_ERROR, 189 GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
188 "Invalid name %s\n", name); 190 "Invalid name %s\n",
189 GNUNET_break (0); 191 name);
192 GNUNET_break (0);
190 fail = GNUNET_YES; 193 fail = GNUNET_YES;
191 } 194 }
192 195
@@ -202,7 +205,6 @@ zone_proc (void *cls,
202 else 205 else
203 GNUNET_SCHEDULER_add_now (&end, NULL); 206 GNUNET_SCHEDULER_add_now (&end, NULL);
204 } 207 }
205
206} 208}
207 209
208 210
@@ -222,11 +224,15 @@ put_cont (void *cls, int32_t success, const char *emsg)
222 if (success == GNUNET_OK) 224 if (success == GNUNET_OK)
223 { 225 {
224 c++; 226 c++;
225 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Created record %u: `%s'\n", c, label); 227 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
228 "Created record %u: `%s'\n",
229 c,
230 label);
226 } 231 }
227 else 232 else
228 { 233 {
229 GNUNET_log (GNUNET_ERROR_TYPE_ERROR, "Failed to created records\n"); 234 GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
235 "Failed to created records\n");
230 GNUNET_break (0); 236 GNUNET_break (0);
231 GNUNET_SCHEDULER_cancel (endbadly_task); 237 GNUNET_SCHEDULER_cancel (endbadly_task);
232 endbadly_task = GNUNET_SCHEDULER_add_now (&endbadly, NULL); 238 endbadly_task = GNUNET_SCHEDULER_add_now (&endbadly, NULL);
@@ -281,7 +287,8 @@ run (void *cls,
281 NULL); 287 NULL);
282 if (NULL == zm) 288 if (NULL == zm)
283 { 289 {
284 GNUNET_log (GNUNET_ERROR_TYPE_ERROR, "Failed to create zone monitor\n"); 290 GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
291 "Failed to create zone monitor\n");
285 GNUNET_break (0); 292 GNUNET_break (0);
286 endbadly_task = GNUNET_SCHEDULER_add_now (&endbadly, NULL); 293 endbadly_task = GNUNET_SCHEDULER_add_now (&endbadly, NULL);
287 return; 294 return;