mirror of
https://github.com/irungentoo/toxcore.git
synced 2024-03-22 13:30:51 +08:00
Fix bad attempt at refactoring
This commit is contained in:
parent
e4d81e1520
commit
e7270aa99d
|
@ -37,13 +37,15 @@ void crypto_memzero(void *data, size_t length)
|
|||
sodium_memzero(data, length);
|
||||
#else
|
||||
#ifdef _WIN32
|
||||
SecureZeroMemory(pnt, len);
|
||||
SecureZeroMemory(data, length);
|
||||
#elif defined(HAVE_MEMSET_S)
|
||||
|
||||
errno_t code = memset_s(data, (rsize_t) length, 0, (rsize_t) length)
|
||||
if (length > 0U) {
|
||||
errno_t code = memset_s(data, (rsize_t) length, 0, (rsize_t) length);
|
||||
|
||||
if (len > 0U && code != 0) {
|
||||
abort(); /* LCOV_EXCL_LINE */
|
||||
if (code != 0) {
|
||||
abort(); /* LCOV_EXCL_LINE */
|
||||
}
|
||||
}
|
||||
|
||||
#elif defined(HAVE_EXPLICIT_BZERO)
|
||||
|
|
Loading…
Reference in New Issue
Block a user