projects
/
oweals
/
gnunet.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
2a9261a
)
-proper branch order
author
Christian Grothoff
<christian@grothoff.org>
Fri, 4 May 2012 07:49:36 +0000
(07:49 +0000)
committer
Christian Grothoff
<christian@grothoff.org>
Fri, 4 May 2012 07:49:36 +0000
(07:49 +0000)
src/util/crypto_aes.c
patch
|
blob
|
history
diff --git
a/src/util/crypto_aes.c
b/src/util/crypto_aes.c
index 7d14131be73a1bd3beb3eb14de2608a77ff94f1b..d5c36d703f619675fd9e41efbdc3844644bd2111 100644
(file)
--- a/
src/util/crypto_aes.c
+++ b/
src/util/crypto_aes.c
@@
-59,10
+59,12
@@
GNUNET_CRYPTO_aes_check_session_key (const struct GNUNET_CRYPTO_AesSessionKey
uint32_t crc;
crc = GNUNET_CRYPTO_crc32_n (key, GNUNET_CRYPTO_AES_KEY_LENGTH);
- if (ntohl (key->crc32) == crc)
- return GNUNET_OK;
- GNUNET_break_op (0);
- return GNUNET_SYSERR;
+ if (ntohl (key->crc32) != crc)
+ {
+ GNUNET_break_op (0);
+ return GNUNET_SYSERR;
+ }
+ return GNUNET_OK;
}