mirror of
https://github.com/status-im/sqlcipher.git
synced 2026-08-30 22:11:14 +00:00
initialize memory in sqlcipher_malloc before use
This commit is contained in:
@@ -186,6 +186,7 @@ void sqlcipher_free(void *ptr, int sz) {
|
||||
*/
|
||||
void* sqlcipher_malloc(int sz) {
|
||||
void *ptr = sqlite3Malloc(sz);
|
||||
memset(ptr, 0, sz);
|
||||
#ifndef OMIT_MEMLOCK
|
||||
if(ptr) {
|
||||
#if defined(__unix__) || defined(__APPLE__)
|
||||
|
||||
Reference in New Issue
Block a user