diff options
author | Richard Levitte <levitte@openssl.org> | 2002-11-28 08:04:36 +0000 |
---|---|---|
committer | Richard Levitte <levitte@openssl.org> | 2002-11-28 08:04:36 +0000 |
commit | 4579924b7e55fccc7013e6de196f2e2ab175ce39 (patch) | |
tree | fa19611a704cc901d3ba338cefbbb98878de7ee5 /crypto/rand/randfile.c | |
parent | 2047bda6fb8bedab1103b7bd5df5ea55eb7ccc9b (diff) | |
download | openssl-4579924b7e55fccc7013e6de196f2e2ab175ce39.tar.gz |
Cleanse memory using the new OPENSSL_cleanse() function.
I've covered all the memset()s I felt safe modifying, but may have missed some.
Diffstat (limited to 'crypto/rand/randfile.c')
-rw-r--r-- | crypto/rand/randfile.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/crypto/rand/randfile.c b/crypto/rand/randfile.c index 7c2673a61f..41574768ab 100644 --- a/crypto/rand/randfile.c +++ b/crypto/rand/randfile.c @@ -124,7 +124,7 @@ int RAND_load_file(const char *file, long bytes) } } fclose(in); - memset(buf,0,BUFSIZE); + OPENSSL_cleanse(buf,BUFSIZE); err: return(ret); } @@ -189,7 +189,7 @@ int RAND_write_file(const char *file) #endif /* OPENSSL_SYS_VMS */ fclose(out); - memset(buf,0,BUFSIZE); + OPENSSL_cleanse(buf,BUFSIZE); err: return (rand_err ? -1 : ret); } |