diff options
author | Christian Grothoff <christian@grothoff.org> | 2013-10-16 20:21:27 +0000 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2013-10-16 20:21:27 +0000 |
commit | accfd6bd85274da2f19e7230c8da6b273cfb2ece (patch) | |
tree | 60966194963795ff07b4da94f4efb6c46d6a23cf /src/namestore/plugin_namestore_postgres.c | |
parent | 3d670727232e79b7e49a1df7ba9260db4e5798a0 (diff) | |
download | gnunet-accfd6bd85274da2f19e7230c8da6b273cfb2ece.tar.gz gnunet-accfd6bd85274da2f19e7230c8da6b273cfb2ece.zip |
-another renaming fest for GNUNET_NAMESTORE_ to GNUNET_GNSRECORD_ symbols that were moved
Diffstat (limited to 'src/namestore/plugin_namestore_postgres.c')
-rw-r--r-- | src/namestore/plugin_namestore_postgres.c | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/src/namestore/plugin_namestore_postgres.c b/src/namestore/plugin_namestore_postgres.c index 0a8f0fbe8..e5cb75eb4 100644 --- a/src/namestore/plugin_namestore_postgres.c +++ b/src/namestore/plugin_namestore_postgres.c | |||
@@ -333,7 +333,7 @@ delete_old_block (struct Plugin *plugin, | |||
333 | */ | 333 | */ |
334 | static int | 334 | static int |
335 | namestore_postgres_cache_block (void *cls, | 335 | namestore_postgres_cache_block (void *cls, |
336 | const struct GNUNET_NAMESTORE_Block *block) | 336 | const struct GNUNET_GNSRECORD_Block *block) |
337 | { | 337 | { |
338 | struct Plugin *plugin = cls; | 338 | struct Plugin *plugin = cls; |
339 | struct GNUNET_HashCode query; | 339 | struct GNUNET_HashCode query; |
@@ -392,7 +392,7 @@ namestore_postgres_cache_block (void *cls, | |||
392 | static int | 392 | static int |
393 | namestore_postgres_lookup_block (void *cls, | 393 | namestore_postgres_lookup_block (void *cls, |
394 | const struct GNUNET_HashCode *query, | 394 | const struct GNUNET_HashCode *query, |
395 | GNUNET_NAMESTORE_BlockCallback iter, void *iter_cls) | 395 | GNUNET_GNSRECORD_BlockCallback iter, void *iter_cls) |
396 | { | 396 | { |
397 | struct Plugin *plugin = cls; | 397 | struct Plugin *plugin = cls; |
398 | const char *paramValues[] = { | 398 | const char *paramValues[] = { |
@@ -405,7 +405,7 @@ namestore_postgres_lookup_block (void *cls, | |||
405 | PGresult *res; | 405 | PGresult *res; |
406 | unsigned int cnt; | 406 | unsigned int cnt; |
407 | size_t bsize; | 407 | size_t bsize; |
408 | const struct GNUNET_NAMESTORE_Block *block; | 408 | const struct GNUNET_GNSRECORD_Block *block; |
409 | 409 | ||
410 | res = PQexecPrepared (plugin->dbh, | 410 | res = PQexecPrepared (plugin->dbh, |
411 | "lookup_block", 1, | 411 | "lookup_block", 1, |
@@ -431,7 +431,7 @@ namestore_postgres_lookup_block (void *cls, | |||
431 | GNUNET_assert (1 == cnt); | 431 | GNUNET_assert (1 == cnt); |
432 | GNUNET_assert (1 != PQnfields (res)); | 432 | GNUNET_assert (1 != PQnfields (res)); |
433 | bsize = PQgetlength (res, 0, 0); | 433 | bsize = PQgetlength (res, 0, 0); |
434 | block = (const struct GNUNET_NAMESTORE_Block *) PQgetvalue (res, 0, 0); | 434 | block = (const struct GNUNET_GNSRECORD_Block *) PQgetvalue (res, 0, 0); |
435 | if ( (bsize < sizeof (*block)) || | 435 | if ( (bsize < sizeof (*block)) || |
436 | (bsize != ntohl (block->purpose.size) + | 436 | (bsize != ntohl (block->purpose.size) + |
437 | sizeof (struct GNUNET_CRYPTO_EcdsaPublicKey) + | 437 | sizeof (struct GNUNET_CRYPTO_EcdsaPublicKey) + |
@@ -465,7 +465,7 @@ namestore_postgres_store_records (void *cls, | |||
465 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone_key, | 465 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone_key, |
466 | const char *label, | 466 | const char *label, |
467 | unsigned int rd_count, | 467 | unsigned int rd_count, |
468 | const struct GNUNET_NAMESTORE_RecordData *rd) | 468 | const struct GNUNET_GNSRECORD_Data *rd) |
469 | { | 469 | { |
470 | struct Plugin *plugin = cls; | 470 | struct Plugin *plugin = cls; |
471 | struct GNUNET_CRYPTO_EcdsaPublicKey pkey; | 471 | struct GNUNET_CRYPTO_EcdsaPublicKey pkey; |
@@ -485,7 +485,7 @@ namestore_postgres_store_records (void *cls, | |||
485 | break; | 485 | break; |
486 | } | 486 | } |
487 | rvalue = GNUNET_CRYPTO_random_u64 (GNUNET_CRYPTO_QUALITY_WEAK, UINT64_MAX); | 487 | rvalue = GNUNET_CRYPTO_random_u64 (GNUNET_CRYPTO_QUALITY_WEAK, UINT64_MAX); |
488 | data_size = GNUNET_NAMESTORE_records_get_size (rd_count, rd); | 488 | data_size = GNUNET_GNSRECORD_records_get_size (rd_count, rd); |
489 | if (data_size > 64 * 65536) | 489 | if (data_size > 64 * 65536) |
490 | { | 490 | { |
491 | GNUNET_break (0); | 491 | GNUNET_break (0); |
@@ -512,7 +512,7 @@ namestore_postgres_store_records (void *cls, | |||
512 | const int paramFormats[] = { 1, 1, 1, 1, 1, 1 }; | 512 | const int paramFormats[] = { 1, 1, 1, 1, 1, 1 }; |
513 | PGresult *res; | 513 | PGresult *res; |
514 | 514 | ||
515 | if (data_size != GNUNET_NAMESTORE_records_serialize (rd_count, rd, | 515 | if (data_size != GNUNET_GNSRECORD_records_serialize (rd_count, rd, |
516 | data_size, data)) | 516 | data_size, data)) |
517 | { | 517 | { |
518 | GNUNET_break (0); | 518 | GNUNET_break (0); |
@@ -610,13 +610,13 @@ get_record_and_call_iterator (struct Plugin *plugin, | |||
610 | return GNUNET_SYSERR; | 610 | return GNUNET_SYSERR; |
611 | } | 611 | } |
612 | { | 612 | { |
613 | struct GNUNET_NAMESTORE_RecordData rd[record_count]; | 613 | struct GNUNET_GNSRECORD_Data rd[record_count]; |
614 | char buf[label_len + 1]; | 614 | char buf[label_len + 1]; |
615 | 615 | ||
616 | memcpy (buf, label, label_len); | 616 | memcpy (buf, label, label_len); |
617 | buf[label_len] = '\0'; | 617 | buf[label_len] = '\0'; |
618 | if (GNUNET_OK != | 618 | if (GNUNET_OK != |
619 | GNUNET_NAMESTORE_records_deserialize (data_size, data, | 619 | GNUNET_GNSRECORD_records_deserialize (data_size, data, |
620 | record_count, rd)) | 620 | record_count, rd)) |
621 | { | 621 | { |
622 | GNUNET_break (0); | 622 | GNUNET_break (0); |