aboutsummaryrefslogtreecommitdiff
path: root/src/namestore/test_namestore_api_create_update.c
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2012-05-27 21:46:41 +0000
committerChristian Grothoff <christian@grothoff.org>2012-05-27 21:46:41 +0000
commit46a63dc665f31fa7d42639ab6adabbdb1af239c8 (patch)
tree6c3e58a7f57d6d3ee44aa6cd2808b5458d75de4b /src/namestore/test_namestore_api_create_update.c
parent4848a679018f9e864cd277345191ad8f1000b5ff (diff)
downloadgnunet-46a63dc665f31fa7d42639ab6adabbdb1af239c8.tar.gz
gnunet-46a63dc665f31fa7d42639ab6adabbdb1af239c8.zip
renaming GNUNET_TIME_relative_get_forever and GNUNET_TIME_absolute_get_forever methods, adding underscore, to make it clear that the respective #defines should be used instead; replacing use of direct function calls with respective macros where applicable; adding additional GNUNET_TIME_relative_get_xxx-functions to avoid calls to GNUNET_TIME_relative_multiply, which turn out to have gotten performance-relevant
Diffstat (limited to 'src/namestore/test_namestore_api_create_update.c')
-rw-r--r--src/namestore/test_namestore_api_create_update.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/namestore/test_namestore_api_create_update.c b/src/namestore/test_namestore_api_create_update.c
index d11c894cc..93570e458 100644
--- a/src/namestore/test_namestore_api_create_update.c
+++ b/src/namestore/test_namestore_api_create_update.c
@@ -294,7 +294,7 @@ void name_lookup_initial_proc (void *cls,
294 294
295 /* create a second record */ 295 /* create a second record */
296 s_second_record = GNUNET_malloc(sizeof (struct GNUNET_NAMESTORE_RecordData) + TEST_CREATE_RECORD_DATALEN); 296 s_second_record = GNUNET_malloc(sizeof (struct GNUNET_NAMESTORE_RecordData) + TEST_CREATE_RECORD_DATALEN);
297 s_second_record->expiration = GNUNET_TIME_absolute_get_forever(); 297 s_second_record->expiration = GNUNET_TIME_UNIT_FOREVER_ABS;
298 s_second_record->record_type = TEST_CREATE_RECORD_TYPE; 298 s_second_record->record_type = TEST_CREATE_RECORD_TYPE;
299 s_second_record->flags = GNUNET_NAMESTORE_RF_AUTHORITY; 299 s_second_record->flags = GNUNET_NAMESTORE_RF_AUTHORITY;
300 s_second_record->data = &s_second_record[1]; 300 s_second_record->data = &s_second_record[1];
@@ -406,11 +406,11 @@ create_record (int count)
406 406
407 for (c = 0; c < count; c++) 407 for (c = 0; c < count; c++)
408 { 408 {
409 rd[c].expiration = GNUNET_TIME_absolute_get_zero(); 409 rd[c].expiration = GNUNET_TIME_UNIT_ZERO_ABS;
410 rd[c].record_type = TEST_RECORD_TYPE; 410 rd[c].record_type = TEST_RECORD_TYPE;
411 rd[c].data_size = TEST_RECORD_DATALEN; 411 rd[c].data_size = TEST_RECORD_DATALEN;
412 rd[c].data = GNUNET_malloc(TEST_RECORD_DATALEN); 412 rd[c].data = GNUNET_malloc(TEST_RECORD_DATALEN);
413 memset ((char *) rd[c].data, TEST_RECORD_DATA, TEST_RECORD_DATALEN); 413 memset ((char *) rd[c].data, TEST_RECORD_DATA, TEST_RECORD_DATALEN);
414 } 414 }
415 415
416 return rd; 416 return rd;