diff options
Diffstat (limited to 'src/revocation/plugin_block_revocation.c')
-rw-r--r-- | src/revocation/plugin_block_revocation.c | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/src/revocation/plugin_block_revocation.c b/src/revocation/plugin_block_revocation.c index 3c9344a49..1928d09cd 100644 --- a/src/revocation/plugin_block_revocation.c +++ b/src/revocation/plugin_block_revocation.c | |||
@@ -134,6 +134,7 @@ block_plugin_revocation_evaluate (void *cls, | |||
134 | { | 134 | { |
135 | struct InternalContext *ic = cls; | 135 | struct InternalContext *ic = cls; |
136 | struct GNUNET_HashCode chash; | 136 | struct GNUNET_HashCode chash; |
137 | ssize_t pklen; | ||
137 | const struct RevokeMessage *rm = reply_block; | 138 | const struct RevokeMessage *rm = reply_block; |
138 | 139 | ||
139 | if (NULL == reply_block) | 140 | if (NULL == reply_block) |
@@ -153,8 +154,14 @@ block_plugin_revocation_evaluate (void *cls, | |||
153 | GNUNET_break_op (0); | 154 | GNUNET_break_op (0); |
154 | return GNUNET_BLOCK_EVALUATION_RESULT_INVALID; | 155 | return GNUNET_BLOCK_EVALUATION_RESULT_INVALID; |
155 | } | 156 | } |
157 | pklen = GNUNET_IDENTITY_key_get_length (pk); | ||
158 | if (0 > pklen) | ||
159 | { | ||
160 | GNUNET_break_op (0); | ||
161 | return GNUNET_BLOCK_EVALUATION_RESULT_INVALID; | ||
162 | } | ||
156 | GNUNET_CRYPTO_hash (pk, | 163 | GNUNET_CRYPTO_hash (pk, |
157 | GNUNET_IDENTITY_key_get_length (pk), | 164 | pklen, |
158 | &chash); | 165 | &chash); |
159 | if (GNUNET_YES == | 166 | if (GNUNET_YES == |
160 | GNUNET_BLOCK_GROUP_bf_test_and_set (group, | 167 | GNUNET_BLOCK_GROUP_bf_test_and_set (group, |