aboutsummaryrefslogtreecommitdiff
path: root/src/reclaim/reclaim_attribute.c
diff options
context:
space:
mode:
authorSchanzenbach, Martin <mschanzenbach@posteo.de>2020-03-03 13:30:53 +0100
committerSchanzenbach, Martin <mschanzenbach@posteo.de>2020-03-03 13:30:53 +0100
commitcd841b66b685604a54030ead95b2d679325d5dd8 (patch)
tree12e536b26ac24fb8a042a8ad5dc14d9b2364ab82 /src/reclaim/reclaim_attribute.c
parentd1bdcb2618b13c3289492347550feb3fcf1f812d (diff)
downloadgnunet-cd841b66b685604a54030ead95b2d679325d5dd8.tar.gz
gnunet-cd841b66b685604a54030ead95b2d679325d5dd8.zip
fix attestation flag rest; fix NULL ptr deref
Diffstat (limited to 'src/reclaim/reclaim_attribute.c')
-rw-r--r--src/reclaim/reclaim_attribute.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/reclaim/reclaim_attribute.c b/src/reclaim/reclaim_attribute.c
index 12f124c15..69c5351d3 100644
--- a/src/reclaim/reclaim_attribute.c
+++ b/src/reclaim/reclaim_attribute.c
@@ -366,6 +366,13 @@ GNUNET_RECLAIM_attribute_list_deserialize (const char *data, size_t data_size)
366 ale->attribute = 366 ale->attribute =
367 GNUNET_RECLAIM_attribute_deserialize (read_ptr, 367 GNUNET_RECLAIM_attribute_deserialize (read_ptr,
368 data_size - (read_ptr - data)); 368 data_size - (read_ptr - data));
369 if (NULL == ale->attribute)
370 {
371 GNUNET_log (GNUNET_ERROR_TYPE_WARNING,
372 "Failed to deserialize malformed attribute.\n");
373 GNUNET_free (ale);
374 return al;
375 }
369 GNUNET_CONTAINER_DLL_insert (al->list_head, al->list_tail, ale); 376 GNUNET_CONTAINER_DLL_insert (al->list_head, al->list_tail, ale);
370 attr_len = GNUNET_RECLAIM_attribute_serialize_get_size (ale->attribute); 377 attr_len = GNUNET_RECLAIM_attribute_serialize_get_size (ale->attribute);
371 read_ptr += attr_len; 378 read_ptr += attr_len;