diff options
Diffstat (limited to 'src/gnsrecord/gnsrecord_crypto.c')
-rw-r--r-- | src/gnsrecord/gnsrecord_crypto.c | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/src/gnsrecord/gnsrecord_crypto.c b/src/gnsrecord/gnsrecord_crypto.c index a83a1c0cd..e11facf78 100644 --- a/src/gnsrecord/gnsrecord_crypto.c +++ b/src/gnsrecord/gnsrecord_crypto.c | |||
@@ -255,11 +255,12 @@ GNUNET_GNSRECORD_block_decrypt (const struct GNUNET_GNSRECORD_Block *block, | |||
255 | { | 255 | { |
256 | if (k == i) | 256 | if (k == i) |
257 | continue; | 257 | continue; |
258 | if ((rd[k].record_type == rd[i].record_type) && | 258 | if (rd[i].expiration_time < now.abs_value_us) |
259 | (rd[k].expiration_time >= now.abs_value_us) && | 259 | include_record = GNUNET_NO; /* Shadow record is expired */ |
260 | (rd[i].expiration_time >= now.abs_value_us) && | 260 | if ((rd[k].record_type == rd[i].record_type) |
261 | (0 == (rd[k].flags & GNUNET_GNSRECORD_RF_SHADOW_RECORD))) | 261 | && (rd[k].expiration_time >= now.abs_value_us) |
262 | include_record = GNUNET_NO; /* We have a non-expired, non-shadow record of the same type */ | 262 | && (0 == (rd[k].flags & GNUNET_GNSRECORD_RF_SHADOW_RECORD))) |
263 | include_record = GNUNET_NO; /* We have a non-expired, non-shadow record of the same type */ | ||
263 | } | 264 | } |
264 | if (GNUNET_YES == include_record) | 265 | if (GNUNET_YES == include_record) |
265 | { | 266 | { |