aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2013-10-16 20:21:27 +0000
committerChristian Grothoff <christian@grothoff.org>2013-10-16 20:21:27 +0000
commitced28e4108921c22e5c8aff39af4f0867b2f55cc (patch)
treeed6169a6f68858a32dcd15b3d96a67a24bcdcd8b
parenta99e246a7f24a29b2abb8e2bc438d4eda512511f (diff)
downloadgnunet-gtk-ced28e4108921c22e5c8aff39af4f0867b2f55cc.tar.gz
gnunet-gtk-ced28e4108921c22e5c8aff39af4f0867b2f55cc.zip
-another renaming fest for GNUNET_NAMESTORE_ to GNUNET_GNSRECORD_ symbols that were moved
-rw-r--r--src/fs/gnunet-fs-gtk.c2
-rw-r--r--src/fs/gnunet-fs-gtk_common.c2
-rw-r--r--src/fs/gnunet-fs-gtk_main-window-search.c12
-rw-r--r--src/namestore/gnunet-namestore-gtk.c106
4 files changed, 61 insertions, 61 deletions
diff --git a/src/fs/gnunet-fs-gtk.c b/src/fs/gnunet-fs-gtk.c
index 21e03743..4ed72592 100644
--- a/src/fs/gnunet-fs-gtk.c
+++ b/src/fs/gnunet-fs-gtk.c
@@ -568,7 +568,7 @@ monitor_zone_records (void *cls,
568 const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone, 568 const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone,
569 const char *label, 569 const char *label,
570 unsigned int rd_count, 570 unsigned int rd_count,
571 const struct GNUNET_NAMESTORE_RecordData *rd) 571 const struct GNUNET_GNSRECORD_Data *rd)
572{ 572{
573 GtkListStore *ls; 573 GtkListStore *ls;
574 GtkTreeModel *tm; 574 GtkTreeModel *tm;
diff --git a/src/fs/gnunet-fs-gtk_common.c b/src/fs/gnunet-fs-gtk_common.c
index c7cfa663..59589d4b 100644
--- a/src/fs/gnunet-fs-gtk_common.c
+++ b/src/fs/gnunet-fs-gtk_common.c
@@ -304,7 +304,7 @@ GNUNET_FS_GTK_handle_uri (const struct GNUNET_FS_Uri *uri,
304 { 304 {
305 const char *ns_zkey; 305 const char *ns_zkey;
306 306
307 ns_zkey = GNUNET_NAMESTORE_pkey_to_zkey (&want); 307 ns_zkey = GNUNET_GNSRECORD_pkey_to_zkey (&want);
308 gtk_entry_set_text (ns_entry, 308 gtk_entry_set_text (ns_entry,
309 ns_zkey); 309 ns_zkey);
310 } 310 }
diff --git a/src/fs/gnunet-fs-gtk_main-window-search.c b/src/fs/gnunet-fs-gtk_main-window-search.c
index 6253fa1f..976964ef 100644
--- a/src/fs/gnunet-fs-gtk_main-window-search.c
+++ b/src/fs/gnunet-fs-gtk_main-window-search.c
@@ -110,7 +110,7 @@ timeout_search_lookup (void *cls,
110static void 110static void
111handle_gns_result (void *cls, 111handle_gns_result (void *cls,
112 uint32_t rd_count, 112 uint32_t rd_count,
113 const struct GNUNET_NAMESTORE_RecordData *rd) 113 const struct GNUNET_GNSRECORD_Data *rd)
114{ 114{
115 struct SearchLookup *sl = cls; 115 struct SearchLookup *sl = cls;
116 unsigned int i; 116 unsigned int i;
@@ -400,7 +400,7 @@ static void
400save_pseudonym_with_nick (struct PseuLookupContext *lctx, 400save_pseudonym_with_nick (struct PseuLookupContext *lctx,
401 const char *nick) 401 const char *nick)
402{ 402{
403 struct GNUNET_NAMESTORE_RecordData rd; 403 struct GNUNET_GNSRECORD_Data rd;
404 struct GNUNET_GTK_MainWindowContext *main_ctx; 404 struct GNUNET_GTK_MainWindowContext *main_ctx;
405 405
406 GNUNET_break (NULL == lctx->nick); 406 GNUNET_break (NULL == lctx->nick);
@@ -419,7 +419,7 @@ save_pseudonym_with_nick (struct PseuLookupContext *lctx,
419 memset (&rd, 0, sizeof (rd)); 419 memset (&rd, 0, sizeof (rd));
420 rd.data_size = sizeof (struct GNUNET_CRYPTO_EcdsaPublicKey); 420 rd.data_size = sizeof (struct GNUNET_CRYPTO_EcdsaPublicKey);
421 rd.data = &lctx->pkey; 421 rd.data = &lctx->pkey;
422 rd.flags = GNUNET_NAMESTORE_RF_PRIVATE; 422 rd.flags = GNUNET_GNSRECORD_RF_PRIVATE;
423 rd.expiration_time = GNUNET_TIME_UNIT_FOREVER_ABS.abs_value_us; 423 rd.expiration_time = GNUNET_TIME_UNIT_FOREVER_ABS.abs_value_us;
424 rd.record_type = GNUNET_GNSRECORD_TYPE_PKEY; 424 rd.record_type = GNUNET_GNSRECORD_TYPE_PKEY;
425 main_ctx = GNUNET_FS_GTK_get_main_context (); 425 main_ctx = GNUNET_FS_GTK_get_main_context ();
@@ -539,7 +539,7 @@ ask_for_nickname (struct PseuLookupContext *lctx)
539static void 539static void
540lookup_finished (void *cls, 540lookup_finished (void *cls,
541 uint32_t rd_count, 541 uint32_t rd_count,
542 const struct GNUNET_NAMESTORE_RecordData *rd) 542 const struct GNUNET_GNSRECORD_Data *rd)
543{ 543{
544 struct PseuLookupContext *lctx = cls; 544 struct PseuLookupContext *lctx = cls;
545 unsigned int i; 545 unsigned int i;
@@ -672,7 +672,7 @@ GNUNET_FS_GTK_save_button_clicked_cb (GtkButton * button,
672 widget = GTK_COMBO_BOX (GNUNET_FS_GTK_get_main_window_object 672 widget = GTK_COMBO_BOX (GNUNET_FS_GTK_get_main_window_object
673 ("main_window_search_namespace_combobox")); 673 ("main_window_search_namespace_combobox"));
674 text = gtk_entry_get_text (GTK_ENTRY (gtk_bin_get_child (GTK_BIN (widget)))); 674 text = gtk_entry_get_text (GTK_ENTRY (gtk_bin_get_child (GTK_BIN (widget))));
675 ret = GNUNET_NAMESTORE_zkey_to_pkey (text, &pkey); 675 ret = GNUNET_GNSRECORD_zkey_to_pkey (text, &pkey);
676 if (GNUNET_OK != ret) 676 if (GNUNET_OK != ret)
677 { 677 {
678 GNUNET_break (0); 678 GNUNET_break (0);
@@ -732,7 +732,7 @@ main_window_search_namespace_combobox_changed_cb (GtkComboBox *widget,
732 int ret; 732 int ret;
733 733
734 text = gtk_entry_get_text (GTK_ENTRY (gtk_bin_get_child (GTK_BIN (widget)))); 734 text = gtk_entry_get_text (GTK_ENTRY (gtk_bin_get_child (GTK_BIN (widget))));
735 ret = GNUNET_NAMESTORE_zkey_to_pkey (text, &pkey); 735 ret = GNUNET_GNSRECORD_zkey_to_pkey (text, &pkey);
736 button = GTK_BUTTON (GNUNET_FS_GTK_get_main_window_object 736 button = GTK_BUTTON (GNUNET_FS_GTK_get_main_window_object
737 ("GNUNET_FS_GTK_save_button")); 737 ("GNUNET_FS_GTK_save_button"));
738 gtk_widget_set_visible (GTK_WIDGET (button), 738 gtk_widget_set_visible (GTK_WIDGET (button),
diff --git a/src/namestore/gnunet-namestore-gtk.c b/src/namestore/gnunet-namestore-gtk.c
index c6f926e1..a23b615e 100644
--- a/src/namestore/gnunet-namestore-gtk.c
+++ b/src/namestore/gnunet-namestore-gtk.c
@@ -245,7 +245,7 @@ struct MoveOperationContext
245 /** 245 /**
246 * Record to merge. 246 * Record to merge.
247 */ 247 */
248 struct GNUNET_NAMESTORE_RecordData rd; 248 struct GNUNET_GNSRECORD_Data rd;
249 249
250}; 250};
251 251
@@ -439,7 +439,7 @@ create_qrcode (unsigned int scale)
439 pseu = gtk_entry_get_text (GTK_ENTRY(entry)); 439 pseu = gtk_entry_get_text (GTK_ENTRY(entry));
440 GNUNET_asprintf (&str, 440 GNUNET_asprintf (&str,
441 "gnunet://gns/%s/%s\n", 441 "gnunet://gns/%s/%s\n",
442 GNUNET_NAMESTORE_z2s (&pubkey), 442 GNUNET_GNSRECORD_z2s (&pubkey),
443 pseu); 443 pseu);
444 if (0 != QRinput_append (qri, 444 if (0 != QRinput_append (qri,
445 QR_MODE_8, 445 QR_MODE_8,
@@ -613,7 +613,7 @@ gnunet_namestore_gtk_qr_saveas_button_clicked_cb (GtkButton *button,
613 */ 613 */
614static int 614static int
615check_record_permitted (unsigned int rd_count, 615check_record_permitted (unsigned int rd_count,
616 const struct GNUNET_NAMESTORE_RecordData *rd, 616 const struct GNUNET_GNSRECORD_Data *rd,
617 gint n_type) 617 gint n_type)
618{ 618{
619 unsigned int i; 619 unsigned int i;
@@ -800,11 +800,11 @@ free_edit_dialog_context (struct EditDialogContext *edc)
800static void 800static void
801merge_with_existing_records (void *cls, 801merge_with_existing_records (void *cls,
802 unsigned int rd_count, 802 unsigned int rd_count,
803 const struct GNUNET_NAMESTORE_RecordData *rd) 803 const struct GNUNET_GNSRECORD_Data *rd)
804{ 804{
805 struct MoveOperationContext *moc = cls; 805 struct MoveOperationContext *moc = cls;
806 struct EditDialogContext *edc = moc->edc; 806 struct EditDialogContext *edc = moc->edc;
807 struct GNUNET_NAMESTORE_RecordData rd_new[rd_count + 1]; 807 struct GNUNET_GNSRECORD_Data rd_new[rd_count + 1];
808 struct OperationContext *oc; 808 struct OperationContext *oc;
809 809
810 GNUNET_CONTAINER_DLL_remove (moc_head, moc_tail, moc); 810 GNUNET_CONTAINER_DLL_remove (moc_head, moc_tail, moc);
@@ -820,7 +820,7 @@ merge_with_existing_records (void *cls,
820 return; 820 return;
821 } 821 }
822 822
823 memcpy (rd_new, rd, rd_count * sizeof (struct GNUNET_NAMESTORE_RecordData)); 823 memcpy (rd_new, rd, rd_count * sizeof (struct GNUNET_GNSRECORD_Data));
824 rd_new[rd_count] = moc->rd; 824 rd_new[rd_count] = moc->rd;
825 /* FIXME: sanity-check merge... */ 825 /* FIXME: sanity-check merge... */
826 oc = GNUNET_new (struct OperationContext); 826 oc = GNUNET_new (struct OperationContext);
@@ -846,7 +846,7 @@ merge_with_existing_records (void *cls,
846 */ 846 */
847static void 847static void
848decrypt_block_for_merge (void *cls, 848decrypt_block_for_merge (void *cls,
849 const struct GNUNET_NAMESTORE_Block *block) 849 const struct GNUNET_GNSRECORD_Block *block)
850{ 850{
851 struct MoveOperationContext *moc = cls; 851 struct MoveOperationContext *moc = cls;
852 struct GNUNET_CRYPTO_EcdsaPublicKey pubkey; 852 struct GNUNET_CRYPTO_EcdsaPublicKey pubkey;
@@ -859,7 +859,7 @@ decrypt_block_for_merge (void *cls,
859 GNUNET_CRYPTO_ecdsa_key_get_public (&moc->pk, 859 GNUNET_CRYPTO_ecdsa_key_get_public (&moc->pk,
860 &pubkey); 860 &pubkey);
861 if (GNUNET_OK != 861 if (GNUNET_OK !=
862 GNUNET_NAMESTORE_block_decrypt (block, 862 GNUNET_GNSRECORD_block_decrypt (block,
863 &pubkey, 863 &pubkey,
864 moc->edc->name, 864 moc->edc->name,
865 &merge_with_existing_records, 865 &merge_with_existing_records,
@@ -888,15 +888,15 @@ edit_dialog_continuation (struct EditDialogContext *edc,
888{ 888{
889 struct RecordInfo *ri = edc->ri; 889 struct RecordInfo *ri = edc->ri;
890 unsigned int rd_count = (NULL == ri) ? 0 : ri->rd_count; 890 unsigned int rd_count = (NULL == ri) ? 0 : ri->rd_count;
891 struct GNUNET_NAMESTORE_RecordData rd_old[rd_count]; 891 struct GNUNET_GNSRECORD_Data rd_old[rd_count];
892 struct GNUNET_NAMESTORE_RecordData rd; 892 struct GNUNET_GNSRECORD_Data rd;
893 void *data; 893 void *data;
894 size_t data_size; 894 size_t data_size;
895 struct OperationContext *oc; 895 struct OperationContext *oc;
896 896
897 if ( (NULL != ri) && 897 if ( (NULL != ri) &&
898 (GNUNET_OK != 898 (GNUNET_OK !=
899 GNUNET_NAMESTORE_records_deserialize (ri->data_size, 899 GNUNET_GNSRECORD_records_deserialize (ri->data_size,
900 ri->data, 900 ri->data,
901 ri->rd_count, 901 ri->rd_count,
902 rd_old)) ) 902 rd_old)) )
@@ -919,15 +919,15 @@ edit_dialog_continuation (struct EditDialogContext *edc,
919 return; 919 return;
920 } 920 }
921 if (edc->n_public) 921 if (edc->n_public)
922 rd.flags = GNUNET_NAMESTORE_RF_NONE; 922 rd.flags = GNUNET_GNSRECORD_RF_NONE;
923 else 923 else
924 rd.flags = GNUNET_NAMESTORE_RF_PRIVATE; 924 rd.flags = GNUNET_GNSRECORD_RF_PRIVATE;
925 if (edc->n_is_shadow) 925 if (edc->n_is_shadow)
926 rd.flags |= GNUNET_NAMESTORE_RF_SHADOW_RECORD; 926 rd.flags |= GNUNET_GNSRECORD_RF_SHADOW_RECORD;
927 rd.record_type = edc->record_type; 927 rd.record_type = edc->record_type;
928 rd.expiration_time = edc->n_exp_time; 928 rd.expiration_time = edc->n_exp_time;
929 if (edc->n_is_relative) 929 if (edc->n_is_relative)
930 rd.flags |= GNUNET_NAMESTORE_RF_RELATIVE_EXPIRATION; 930 rd.flags |= GNUNET_GNSRECORD_RF_RELATIVE_EXPIRATION;
931 rd.data_size = data_size; 931 rd.data_size = data_size;
932 rd.data = data; 932 rd.data = data;
933 switch (ret) 933 switch (ret)
@@ -936,10 +936,10 @@ edit_dialog_continuation (struct EditDialogContext *edc,
936 if (GNUNET_YES == edc->old_record_in_namestore) 936 if (GNUNET_YES == edc->old_record_in_namestore)
937 { 937 {
938 /* remove item from tree view and namestore */ 938 /* remove item from tree view and namestore */
939 struct GNUNET_NAMESTORE_RecordData rd_new[rd_count - 1]; 939 struct GNUNET_GNSRECORD_Data rd_new[rd_count - 1];
940 940
941 GNUNET_assert (NULL != ri); 941 GNUNET_assert (NULL != ri);
942 memcpy (rd_new, rd_old, (rd_count - 1) * sizeof (struct GNUNET_NAMESTORE_RecordData)); 942 memcpy (rd_new, rd_old, (rd_count - 1) * sizeof (struct GNUNET_GNSRECORD_Data));
943 rd_new[edc->off] = rd_old[rd_count - 1]; 943 rd_new[edc->off] = rd_old[rd_count - 1];
944 oc = GNUNET_new (struct OperationContext); 944 oc = GNUNET_new (struct OperationContext);
945 GNUNET_CONTAINER_DLL_insert (oc_head, oc_tail, oc); 945 GNUNET_CONTAINER_DLL_insert (oc_head, oc_tail, oc);
@@ -962,10 +962,10 @@ edit_dialog_continuation (struct EditDialogContext *edc,
962 { 962 {
963 if (GNUNET_YES == edc->old_record_in_namestore) 963 if (GNUNET_YES == edc->old_record_in_namestore)
964 { 964 {
965 struct GNUNET_NAMESTORE_RecordData rd_new[rd_count]; 965 struct GNUNET_GNSRECORD_Data rd_new[rd_count];
966 966
967 GNUNET_assert (NULL != ri); 967 GNUNET_assert (NULL != ri);
968 memcpy (rd_new, rd_old, rd_count * sizeof (struct GNUNET_NAMESTORE_RecordData)); 968 memcpy (rd_new, rd_old, rd_count * sizeof (struct GNUNET_GNSRECORD_Data));
969 rd_new[edc->off] = rd; 969 rd_new[edc->off] = rd;
970 oc = GNUNET_new (struct OperationContext); 970 oc = GNUNET_new (struct OperationContext);
971 GNUNET_CONTAINER_DLL_insert (oc_head, oc_tail, oc); 971 GNUNET_CONTAINER_DLL_insert (oc_head, oc_tail, oc);
@@ -977,9 +977,9 @@ edit_dialog_continuation (struct EditDialogContext *edc,
977 } 977 }
978 else 978 else
979 { 979 {
980 struct GNUNET_NAMESTORE_RecordData rd_new[rd_count + 1]; 980 struct GNUNET_GNSRECORD_Data rd_new[rd_count + 1];
981 981
982 memcpy (rd_new, rd_old, rd_count * sizeof (struct GNUNET_NAMESTORE_RecordData)); 982 memcpy (rd_new, rd_old, rd_count * sizeof (struct GNUNET_GNSRECORD_Data));
983 rd_new[rd_count] = rd; 983 rd_new[rd_count] = rd;
984 oc = GNUNET_new (struct OperationContext); 984 oc = GNUNET_new (struct OperationContext);
985 GNUNET_CONTAINER_DLL_insert (oc_head, oc_tail, oc); 985 GNUNET_CONTAINER_DLL_insert (oc_head, oc_tail, oc);
@@ -1000,7 +1000,7 @@ edit_dialog_continuation (struct EditDialogContext *edc,
1000 GNUNET_assert (NULL != edc->ego); 1000 GNUNET_assert (NULL != edc->ego);
1001 pk = GNUNET_IDENTITY_ego_get_private_key (edc->ego); 1001 pk = GNUNET_IDENTITY_ego_get_private_key (edc->ego);
1002 GNUNET_assert (NULL != pk); 1002 GNUNET_assert (NULL != pk);
1003 GNUNET_NAMESTORE_query_from_private_key (pk, 1003 GNUNET_GNSRECORD_query_from_private_key (pk,
1004 edc->name, 1004 edc->name,
1005 &query); 1005 &query);
1006 moc = GNUNET_new (struct MoveOperationContext); 1006 moc = GNUNET_new (struct MoveOperationContext);
@@ -1017,10 +1017,10 @@ edit_dialog_continuation (struct EditDialogContext *edc,
1017 if (GNUNET_YES == edc->old_record_in_namestore) 1017 if (GNUNET_YES == edc->old_record_in_namestore)
1018 { 1018 {
1019 /* remove item from tree view and namestore */ 1019 /* remove item from tree view and namestore */
1020 struct GNUNET_NAMESTORE_RecordData rd_new[rd_count - 1]; 1020 struct GNUNET_GNSRECORD_Data rd_new[rd_count - 1];
1021 1021
1022 GNUNET_assert (NULL != ri); 1022 GNUNET_assert (NULL != ri);
1023 memcpy (rd_new, rd_old, (rd_count - 1) * sizeof (struct GNUNET_NAMESTORE_RecordData)); 1023 memcpy (rd_new, rd_old, (rd_count - 1) * sizeof (struct GNUNET_GNSRECORD_Data));
1024 rd_new[edc->off] = rd_old[rd_count - 1]; 1024 rd_new[edc->off] = rd_old[rd_count - 1];
1025 oc = GNUNET_new (struct OperationContext); 1025 oc = GNUNET_new (struct OperationContext);
1026 GNUNET_CONTAINER_DLL_insert (oc_head, oc_tail, oc); 1026 GNUNET_CONTAINER_DLL_insert (oc_head, oc_tail, oc);
@@ -1065,19 +1065,19 @@ launch_edit_dialog (gint n_type,
1065 if ( (NULL != ri) && 1065 if ( (NULL != ri) &&
1066 (off < ri->rd_count) ) 1066 (off < ri->rd_count) )
1067 { 1067 {
1068 struct GNUNET_NAMESTORE_RecordData rd_old[ri->rd_count]; 1068 struct GNUNET_GNSRECORD_Data rd_old[ri->rd_count];
1069 1069
1070 GNUNET_break (GNUNET_OK == 1070 GNUNET_break (GNUNET_OK ==
1071 GNUNET_NAMESTORE_records_deserialize (ri->data_size, 1071 GNUNET_GNSRECORD_records_deserialize (ri->data_size,
1072 ri->data, 1072 ri->data,
1073 ri->rd_count, 1073 ri->rd_count,
1074 rd_old)); 1074 rd_old));
1075 edc->n_value = GNUNET_GNSRECORD_value_to_string (n_type, 1075 edc->n_value = GNUNET_GNSRECORD_value_to_string (n_type,
1076 rd_old[off].data, 1076 rd_old[off].data,
1077 rd_old[off].data_size); 1077 rd_old[off].data_size);
1078 edc->n_public = (0 == (rd_old[off].flags & GNUNET_NAMESTORE_RF_PRIVATE)); 1078 edc->n_public = (0 == (rd_old[off].flags & GNUNET_GNSRECORD_RF_PRIVATE));
1079 edc->n_is_relative = (0 != (rd_old[off].flags & GNUNET_NAMESTORE_RF_RELATIVE_EXPIRATION)); 1079 edc->n_is_relative = (0 != (rd_old[off].flags & GNUNET_GNSRECORD_RF_RELATIVE_EXPIRATION));
1080 edc->n_is_shadow = (0 != (rd_old[off].flags & GNUNET_NAMESTORE_RF_SHADOW_RECORD)); 1080 edc->n_is_shadow = (0 != (rd_old[off].flags & GNUNET_GNSRECORD_RF_SHADOW_RECORD));
1081 edc->n_exp_time = rd_old[off].expiration_time; 1081 edc->n_exp_time = rd_old[off].expiration_time;
1082 edc->old_record_in_namestore = GNUNET_YES; 1082 edc->old_record_in_namestore = GNUNET_YES;
1083 } 1083 }
@@ -1155,10 +1155,10 @@ static int
1155check_permissions (struct RecordInfo *ri, 1155check_permissions (struct RecordInfo *ri,
1156 guint n_type) 1156 guint n_type)
1157{ 1157{
1158 struct GNUNET_NAMESTORE_RecordData rd[ri->rd_count]; 1158 struct GNUNET_GNSRECORD_Data rd[ri->rd_count];
1159 1159
1160 GNUNET_break (GNUNET_OK == 1160 GNUNET_break (GNUNET_OK ==
1161 GNUNET_NAMESTORE_records_deserialize (ri->data_size, 1161 GNUNET_GNSRECORD_records_deserialize (ri->data_size,
1162 ri->data, 1162 ri->data,
1163 ri->rd_count, 1163 ri->rd_count,
1164 rd)); 1164 rd));
@@ -1493,9 +1493,9 @@ gnunet_namestore_gtk_treeview_key_press_event_cb (GtkWidget *widget,
1493 if ( (gtk_tree_model_iter_parent (tm, &parent, &iter)) && 1493 if ( (gtk_tree_model_iter_parent (tm, &parent, &iter)) &&
1494 (ri->rd_count > 0) ) 1494 (ri->rd_count > 0) )
1495 { 1495 {
1496 struct GNUNET_NAMESTORE_RecordData rd_old[ri->rd_count]; 1496 struct GNUNET_GNSRECORD_Data rd_old[ri->rd_count];
1497 struct GNUNET_NAMESTORE_RecordData rd_new[ri->rd_count - 1]; 1497 struct GNUNET_GNSRECORD_Data rd_new[ri->rd_count - 1];
1498 struct GNUNET_NAMESTORE_RecordData rd; 1498 struct GNUNET_GNSRECORD_Data rd;
1499 unsigned int off; 1499 unsigned int off;
1500 int n_type; 1500 int n_type;
1501 gboolean n_public; 1501 gboolean n_public;
@@ -1509,7 +1509,7 @@ gnunet_namestore_gtk_treeview_key_press_event_cb (GtkWidget *widget,
1509 "Removing single record for name `%s'\n", 1509 "Removing single record for name `%s'\n",
1510 name); 1510 name);
1511 GNUNET_break (GNUNET_OK == 1511 GNUNET_break (GNUNET_OK ==
1512 GNUNET_NAMESTORE_records_deserialize (ri->data_size, 1512 GNUNET_GNSRECORD_records_deserialize (ri->data_size,
1513 ri->data, 1513 ri->data,
1514 ri->rd_count, 1514 ri->rd_count,
1515 rd_old)); 1515 rd_old));
@@ -1523,13 +1523,13 @@ gnunet_namestore_gtk_treeview_key_press_event_cb (GtkWidget *widget,
1523 -1); 1523 -1);
1524 /* valid name */ 1524 /* valid name */
1525 if (n_public) 1525 if (n_public)
1526 rd.flags = GNUNET_NAMESTORE_RF_NONE; 1526 rd.flags = GNUNET_GNSRECORD_RF_NONE;
1527 else 1527 else
1528 rd.flags = GNUNET_NAMESTORE_RF_PRIVATE; 1528 rd.flags = GNUNET_GNSRECORD_RF_PRIVATE;
1529 if (n_is_relative) 1529 if (n_is_relative)
1530 rd.flags |= GNUNET_NAMESTORE_RF_RELATIVE_EXPIRATION; 1530 rd.flags |= GNUNET_GNSRECORD_RF_RELATIVE_EXPIRATION;
1531 if (n_is_shadow) 1531 if (n_is_shadow)
1532 rd.flags |= GNUNET_NAMESTORE_RF_SHADOW_RECORD; 1532 rd.flags |= GNUNET_GNSRECORD_RF_SHADOW_RECORD;
1533 rd.record_type = n_type; 1533 rd.record_type = n_type;
1534 rd.expiration_time = n_exp_time; 1534 rd.expiration_time = n_exp_time;
1535 if (GNUNET_OK != 1535 if (GNUNET_OK !=
@@ -1544,11 +1544,11 @@ gnunet_namestore_gtk_treeview_key_press_event_cb (GtkWidget *widget,
1544 } 1544 }
1545 for (off=0;off<ri->rd_count;off++) 1545 for (off=0;off<ri->rd_count;off++)
1546 if (GNUNET_YES == 1546 if (GNUNET_YES ==
1547 GNUNET_NAMESTORE_records_cmp (&rd, 1547 GNUNET_GNSRECORD_records_cmp (&rd,
1548 &rd_old[off])) 1548 &rd_old[off]))
1549 break; 1549 break;
1550 GNUNET_assert (off != ri->rd_count); 1550 GNUNET_assert (off != ri->rd_count);
1551 memcpy (rd_new, rd_old, (ri->rd_count - 1) * sizeof (struct GNUNET_NAMESTORE_RecordData)); 1551 memcpy (rd_new, rd_old, (ri->rd_count - 1) * sizeof (struct GNUNET_GNSRECORD_Data));
1552 rd_new[off] = rd_old[ri->rd_count - 1]; 1552 rd_new[off] = rd_old[ri->rd_count - 1];
1553 oc = GNUNET_new (struct OperationContext); 1553 oc = GNUNET_new (struct OperationContext);
1554 GNUNET_CONTAINER_DLL_insert (oc_head, oc_tail, oc); 1554 GNUNET_CONTAINER_DLL_insert (oc_head, oc_tail, oc);
@@ -1626,19 +1626,19 @@ gnunet_namestore_gtk_pseu_entry_changed_cb (GtkEditable *editable,
1626 1626
1627 /* get old records, append new one or update/remove existing one */ 1627 /* get old records, append new one or update/remove existing one */
1628 { 1628 {
1629 struct GNUNET_NAMESTORE_RecordData rd_old[rd_count]; 1629 struct GNUNET_GNSRECORD_Data rd_old[rd_count];
1630 struct GNUNET_NAMESTORE_RecordData rd_new[rd_count + 1]; 1630 struct GNUNET_GNSRECORD_Data rd_new[rd_count + 1];
1631 unsigned int off; 1631 unsigned int off;
1632 unsigned int total; 1632 unsigned int total;
1633 1633
1634 total = rd_count; 1634 total = rd_count;
1635 if (NULL != ri) 1635 if (NULL != ri)
1636 GNUNET_break (GNUNET_OK == 1636 GNUNET_break (GNUNET_OK ==
1637 GNUNET_NAMESTORE_records_deserialize (ri->data_size, 1637 GNUNET_GNSRECORD_records_deserialize (ri->data_size,
1638 ri->data, 1638 ri->data,
1639 rd_count, 1639 rd_count,
1640 rd_old)); 1640 rd_old));
1641 memcpy (rd_new, rd_old, sizeof (struct GNUNET_NAMESTORE_RecordData) * rd_count); 1641 memcpy (rd_new, rd_old, sizeof (struct GNUNET_GNSRECORD_Data) * rd_count);
1642 for (off=0;off<rd_count;off++) 1642 for (off=0;off<rd_count;off++)
1643 if (GNUNET_GNSRECORD_TYPE_PSEU == rd_new[off].record_type) 1643 if (GNUNET_GNSRECORD_TYPE_PSEU == rd_new[off].record_type)
1644 break; 1644 break;
@@ -1654,7 +1654,7 @@ gnunet_namestore_gtk_pseu_entry_changed_cb (GtkEditable *editable,
1654 { 1654 {
1655 rd_new[off].record_type = GNUNET_GNSRECORD_TYPE_PSEU; 1655 rd_new[off].record_type = GNUNET_GNSRECORD_TYPE_PSEU;
1656 rd_new[off].expiration_time = UINT64_MAX; 1656 rd_new[off].expiration_time = UINT64_MAX;
1657 rd_new[off].flags = GNUNET_NAMESTORE_RF_NONE; 1657 rd_new[off].flags = GNUNET_GNSRECORD_RF_NONE;
1658 rd_new[off].data_size = strlen (pseu) + 1; 1658 rd_new[off].data_size = strlen (pseu) + 1;
1659 rd_new[off].data = pseu; 1659 rd_new[off].data = pseu;
1660 } 1660 }
@@ -1690,7 +1690,7 @@ gnunet_namestore_gtk_public_key_copy_button_clicked_cb (GtkButton *button,
1690 return; 1690 return;
1691 cb = gtk_clipboard_get (GDK_SELECTION_CLIPBOARD); 1691 cb = gtk_clipboard_get (GDK_SELECTION_CLIPBOARD);
1692 gtk_clipboard_set_text (cb, 1692 gtk_clipboard_set_text (cb,
1693 GNUNET_NAMESTORE_z2s (&pubkey), 1693 GNUNET_GNSRECORD_z2s (&pubkey),
1694 -1); 1694 -1);
1695} 1695}
1696 1696
@@ -1736,7 +1736,7 @@ zone_iteration_proc (void *cls,
1736 const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone_key, 1736 const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone_key,
1737 const char *name, 1737 const char *name,
1738 unsigned int rd_count, 1738 unsigned int rd_count,
1739 const struct GNUNET_NAMESTORE_RecordData *rd) 1739 const struct GNUNET_GNSRECORD_Data *rd)
1740{ 1740{
1741 GtkTreeRowReference *rr; 1741 GtkTreeRowReference *rr;
1742 GtkTreePath *path; 1742 GtkTreePath *path;
@@ -1838,11 +1838,11 @@ zone_iteration_proc (void *cls,
1838 /* update record info serialized version of the records */ 1838 /* update record info serialized version of the records */
1839 GNUNET_free_non_null (ri->data); 1839 GNUNET_free_non_null (ri->data);
1840 ri->rd_count = rd_count; 1840 ri->rd_count = rd_count;
1841 ri->data_size = GNUNET_NAMESTORE_records_get_size (rd_count, rd); 1841 ri->data_size = GNUNET_GNSRECORD_records_get_size (rd_count, rd);
1842 if (0 != ri->data_size) 1842 if (0 != ri->data_size)
1843 ri->data = GNUNET_malloc (ri->data_size); 1843 ri->data = GNUNET_malloc (ri->data_size);
1844 GNUNET_break (ri->data_size == 1844 GNUNET_break (ri->data_size ==
1845 GNUNET_NAMESTORE_records_serialize (rd_count, rd, 1845 GNUNET_GNSRECORD_records_serialize (rd_count, rd,
1846 ri->data_size, ri->data)); 1846 ri->data_size, ri->data));
1847 1847
1848 /* Append elements for records in tree view */ 1848 /* Append elements for records in tree view */
@@ -1855,9 +1855,9 @@ zone_iteration_proc (void *cls,
1855 rd[c].data_size); 1855 rd[c].data_size);
1856 1856
1857 /* Set public toggle */ 1857 /* Set public toggle */
1858 public = ((rd[c].flags & GNUNET_NAMESTORE_RF_PRIVATE) != GNUNET_NAMESTORE_RF_PRIVATE); 1858 public = ((rd[c].flags & GNUNET_GNSRECORD_RF_PRIVATE) != GNUNET_GNSRECORD_RF_PRIVATE);
1859 /* Expiration time */ 1859 /* Expiration time */
1860 time_is_relative = (0 != (rd[c].flags & GNUNET_NAMESTORE_RF_RELATIVE_EXPIRATION)); 1860 time_is_relative = (0 != (rd[c].flags & GNUNET_GNSRECORD_RF_RELATIVE_EXPIRATION));
1861 1861
1862 if (time_is_relative) 1862 if (time_is_relative)
1863 { 1863 {
@@ -1975,7 +1975,7 @@ load_zone (const char *name,
1975 *pkey = *GNUNET_IDENTITY_ego_get_private_key (ego); 1975 *pkey = *GNUNET_IDENTITY_ego_get_private_key (ego);
1976 GNUNET_CRYPTO_ecdsa_key_get_public (pkey, &pubkey); 1976 GNUNET_CRYPTO_ecdsa_key_get_public (pkey, &pubkey);
1977 label = g_markup_printf_escaped (_("<b>Editing zone %s</b>"), 1977 label = g_markup_printf_escaped (_("<b>Editing zone %s</b>"),
1978 GNUNET_NAMESTORE_z2s (&pubkey)); 1978 GNUNET_GNSRECORD_z2s (&pubkey));
1979 gtk_label_set_markup (GTK_LABEL (get_object ("gnunet_namestore_gtk_zone_label")), 1979 gtk_label_set_markup (GTK_LABEL (get_object ("gnunet_namestore_gtk_zone_label")),
1980 label); 1980 label);
1981 g_free (label); 1981 g_free (label);