diff options
author | Schanzenbach, Martin <mschanzenbach@posteo.de> | 2020-02-06 18:38:02 +0100 |
---|---|---|
committer | Schanzenbach, Martin <mschanzenbach@posteo.de> | 2020-02-09 20:38:11 +0100 |
commit | 02daf09b5348ffa894621f59ba0d3497a74ff669 (patch) | |
tree | 1a6bb5d7ae751808c8e93c349ac4ba73d00b9aa7 /src/reclaim/gnunet-service-reclaim.c | |
parent | 5fb277e8d012d687f4d2d032571cd4b57946bbfb (diff) | |
download | gnunet-02daf09b5348ffa894621f59ba0d3497a74ff669.tar.gz gnunet-02daf09b5348ffa894621f59ba0d3497a74ff669.zip |
bugfixes
Diffstat (limited to 'src/reclaim/gnunet-service-reclaim.c')
-rw-r--r-- | src/reclaim/gnunet-service-reclaim.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/reclaim/gnunet-service-reclaim.c b/src/reclaim/gnunet-service-reclaim.c index 99831172b..eb8727f8f 100644 --- a/src/reclaim/gnunet-service-reclaim.c +++ b/src/reclaim/gnunet-service-reclaim.c | |||
@@ -1859,6 +1859,7 @@ attest_iter_finished (void *cls) | |||
1859 | env = GNUNET_MQ_msg (arm, GNUNET_MESSAGE_TYPE_RECLAIM_ATTESTATION_RESULT); | 1859 | env = GNUNET_MQ_msg (arm, GNUNET_MESSAGE_TYPE_RECLAIM_ATTESTATION_RESULT); |
1860 | arm->id = htonl (ai->request_id); | 1860 | arm->id = htonl (ai->request_id); |
1861 | arm->attestation_len = htons (0); | 1861 | arm->attestation_len = htons (0); |
1862 | arm->attributes_len = htons (0); | ||
1862 | GNUNET_MQ_send (ai->client->mq, env); | 1863 | GNUNET_MQ_send (ai->client->mq, env); |
1863 | GNUNET_CONTAINER_DLL_remove (ai->client->attest_iter_head, | 1864 | GNUNET_CONTAINER_DLL_remove (ai->client->attest_iter_head, |
1864 | ai->client->attest_iter_tail, | 1865 | ai->client->attest_iter_tail, |
@@ -1900,10 +1901,11 @@ attest_iter_cb (void *cls, | |||
1900 | { | 1901 | { |
1901 | struct Iterator *ai = cls; | 1902 | struct Iterator *ai = cls; |
1902 | struct GNUNET_MQ_Envelope *env; | 1903 | struct GNUNET_MQ_Envelope *env; |
1904 | struct AttestationResultMessage *arm; | ||
1903 | struct GNUNET_RECLAIM_AttributeList *attrs; | 1905 | struct GNUNET_RECLAIM_AttributeList *attrs; |
1904 | struct GNUNET_RECLAIM_Attestation *att; | 1906 | struct GNUNET_RECLAIM_Attestation *att; |
1905 | char *data_tmp; | 1907 | char *data_tmp; |
1906 | char *attrs_size; | 1908 | size_t attrs_size; |
1907 | 1909 | ||
1908 | if ((rd_count != 1) || | 1910 | if ((rd_count != 1) || |
1909 | (GNUNET_GNSRECORD_TYPE_RECLAIM_ATTESTATION != rd->record_type)) | 1911 | (GNUNET_GNSRECORD_TYPE_RECLAIM_ATTESTATION != rd->record_type)) |
@@ -1915,8 +1917,6 @@ attest_iter_cb (void *cls, | |||
1915 | rd->data_size); | 1917 | rd->data_size); |
1916 | attrs = GNUNET_RECLAIM_attestation_get_attributes (att); | 1918 | attrs = GNUNET_RECLAIM_attestation_get_attributes (att); |
1917 | attrs_size = GNUNET_RECLAIM_attribute_list_serialize_get_size (attrs); | 1919 | attrs_size = GNUNET_RECLAIM_attribute_list_serialize_get_size (attrs); |
1918 | |||
1919 | struct AttestationResultMessage *arm; | ||
1920 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Found attestation under: %s\n", | 1920 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Found attestation under: %s\n", |
1921 | label); | 1921 | label); |
1922 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 1922 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
@@ -1926,6 +1926,7 @@ attest_iter_cb (void *cls, | |||
1926 | GNUNET_MESSAGE_TYPE_RECLAIM_ATTESTATION_RESULT); | 1926 | GNUNET_MESSAGE_TYPE_RECLAIM_ATTESTATION_RESULT); |
1927 | arm->id = htonl (ai->request_id); | 1927 | arm->id = htonl (ai->request_id); |
1928 | arm->attestation_len = htons (rd->data_size); | 1928 | arm->attestation_len = htons (rd->data_size); |
1929 | arm->attributes_len = htons (attrs_size); | ||
1929 | GNUNET_CRYPTO_ecdsa_key_get_public (zone, &arm->identity); | 1930 | GNUNET_CRYPTO_ecdsa_key_get_public (zone, &arm->identity); |
1930 | data_tmp = (char *) &arm[1]; | 1931 | data_tmp = (char *) &arm[1]; |
1931 | GNUNET_memcpy (data_tmp, rd->data, rd->data_size); | 1932 | GNUNET_memcpy (data_tmp, rd->data, rd->data_size); |