diff options
author | Matthias Wachs <wachs@net.in.tum.de> | 2013-11-04 17:04:28 +0000 |
---|---|---|
committer | Matthias Wachs <wachs@net.in.tum.de> | 2013-11-04 17:04:28 +0000 |
commit | 6c3bf6b3486fd31402ab991f5ddef76bf9cd93c4 (patch) | |
tree | 86ff97f084276e63ad6d58fd398b8dc1403199bb /src/gnsrecord/gnsrecord_crypto.c | |
parent | a5328c2a96b9582585511c1ce1aee08509eb0c0a (diff) | |
download | gnunet-6c3bf6b3486fd31402ab991f5ddef76bf9cd93c4.tar.gz gnunet-6c3bf6b3486fd31402ab991f5ddef76bf9cd93c4.zip |
block expiration
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 | { |