make data pointers volatile so that memory zeroing won't get optimised away

--HG--
branch : libtomcrypt
extra : convert_revision : fa68f28b581de8ed5f2af8f1ab95b33bcf4a7e18
This commit is contained in:
Matt Johnston
2005-01-02 17:09:05 +00:00
parent 2b69e81c3d
commit ef7fcc83a7

View File

@@ -12,7 +12,7 @@
void zeromem(void *dst, size_t len)
{
unsigned char *mem = (unsigned char *)dst;
volatile unsigned char *mem = (unsigned char *)dst;
_ARGCHK(dst != NULL);
while (len-- > 0)
*mem++ = 0;