aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSchanzenbach, Martin <martin.schanzenbach@aisec.fraunhofer.de>2018-01-05 15:37:00 +0100
committerSchanzenbach, Martin <martin.schanzenbach@aisec.fraunhofer.de>2018-01-05 15:37:00 +0100
commit7cad4a8604812fcea3178a6a6cb411b0237776ca (patch)
treeabf0b9012e6c8f53d4d0e8f5fdc06922efa5be1d
parentada1ee79ada47e17c970ea9cddebfca1261259a7 (diff)
parent48fc70932f0074447d2ab821f2babb5bfe754a1e (diff)
downloadgnunet-7cad4a8604812fcea3178a6a6cb411b0237776ca.tar.gz
gnunet-7cad4a8604812fcea3178a6a6cb411b0237776ca.zip
Merge branch 'master' of git+ssh://gnunet.org/gnunet
-rw-r--r--src/set/set_api.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/set/set_api.c b/src/set/set_api.c
index 1d0d00b44..cefc6734a 100644
--- a/src/set/set_api.c
+++ b/src/set/set_api.c
@@ -695,6 +695,7 @@ GNUNET_SET_add_element (struct GNUNET_SET_Handle *set,
695 "adding element of type %u to set %p\n", 695 "adding element of type %u to set %p\n",
696 (unsigned int) element->element_type, 696 (unsigned int) element->element_type,
697 set); 697 set);
698 GNUNET_assert (NULL != set);
698 if (GNUNET_YES == set->invalid) 699 if (GNUNET_YES == set->invalid)
699 { 700 {
700 if (NULL != cont) 701 if (NULL != cont)
@@ -772,6 +773,7 @@ GNUNET_SET_destroy (struct GNUNET_SET_Handle *set)
772 /* destroying set while iterator is active is currently 773 /* destroying set while iterator is active is currently
773 not supported; we should expand the API to allow 774 not supported; we should expand the API to allow
774 clients to explicitly cancel the iteration! */ 775 clients to explicitly cancel the iteration! */
776 GNUNET_assert (NULL != set);
775 if ( (NULL != set->ops_head) || 777 if ( (NULL != set->ops_head) ||
776 (NULL != set->iterator) || 778 (NULL != set->iterator) ||
777 (GNUNET_SYSERR == set->destroy_requested) ) 779 (GNUNET_SYSERR == set->destroy_requested) )
@@ -1124,11 +1126,12 @@ GNUNET_SET_commit (struct GNUNET_SET_OperationHandle *oh,
1124{ 1126{
1125 if (NULL != oh->set) 1127 if (NULL != oh->set)
1126 { 1128 {
1127 /* Some other set was already commited for this 1129 /* Some other set was already committed for this
1128 * operation, there is a logic bug in the client of this API */ 1130 * operation, there is a logic bug in the client of this API */
1129 GNUNET_break (0); 1131 GNUNET_break (0);
1130 return GNUNET_OK; 1132 return GNUNET_OK;
1131 } 1133 }
1134 GNUNET_assert (NULL != set);
1132 if (GNUNET_YES == set->invalid) 1135 if (GNUNET_YES == set->invalid)
1133 return GNUNET_SYSERR; 1136 return GNUNET_SYSERR;
1134 LOG (GNUNET_ERROR_TYPE_DEBUG, 1137 LOG (GNUNET_ERROR_TYPE_DEBUG,