projects
/
oweals
/
openssl.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
a067cba
)
Make CRYPTO_cleanse() independent of endianness.
author
Richard Levitte
<levitte@openssl.org>
Tue, 3 Dec 2002 16:07:03 +0000
(16:07 +0000)
committer
Richard Levitte
<levitte@openssl.org>
Tue, 3 Dec 2002 16:07:03 +0000
(16:07 +0000)
crypto/mem_clr.c
patch
|
blob
|
history
diff --git
a/crypto/mem_clr.c
b/crypto/mem_clr.c
index 0b72966cfa1b480edb675d095e7458b17b887423..e4b7f540b0bd12dd03608b52e8214332cb1a8b72 100644
(file)
--- a/
crypto/mem_clr.c
+++ b/
crypto/mem_clr.c
@@
-68,7
+68,7
@@
void OPENSSL_cleanse(void *ptr, size_t len)
while(loop--)
{
*(p++) = cleanse_ctr;
- cleanse_ctr += (17 + (
((unsigned char *)&p)[sizeof(unsigned char *)-1]
& 0xF));
+ cleanse_ctr += (17 + (
unsigned char)((int)p
& 0xF));
}
if(memchr(ptr, cleanse_ctr, len))
cleanse_ctr += 63;