File tree Expand file tree Collapse file tree 1 file changed +6
-6
lines changed Expand file tree Collapse file tree 1 file changed +6
-6
lines changed Original file line number Diff line number Diff line change 5
5
#include "btreeInt.h"
6
6
#include "crypto.h"
7
7
#ifndef OMIT_MEMLOCK
8
- #if defined __unix__ || defined MAC_OS_X
8
+ #if defined( __unix__ ) || defined( __APPLE__ )
9
9
#include <sys/mman.h>
10
- #elif defined _WIN32
10
+ #elif defined( _WIN32 )
11
11
# include <windows.h>
12
12
#endif
13
13
#endif
@@ -89,9 +89,9 @@ void sqlcipher_free(void *ptr, int sz) {
89
89
if (sz > 0 ) {
90
90
memset (ptr , 0 , sz );
91
91
#ifndef OMIT_MEMLOCK
92
- #if defined __unix__ || defined MAC_OS_X
92
+ #if defined( __unix__ ) || defined( __APPLE__ )
93
93
munlock (ptr , sz );
94
- #elif defined _WIN32
94
+ #elif defined( _WIN32 )
95
95
VirtualUnlock (ptr , sz );
96
96
#endif
97
97
#endif
@@ -109,9 +109,9 @@ void* sqlcipher_malloc(size_t sz) {
109
109
void * ptr = sqlite3Malloc (sz );
110
110
#ifndef OMIT_MEMLOCK
111
111
if (ptr ) {
112
- #ifdef __unix__
112
+ #if defined( __unix__ ) || defined( __APPLE__ )
113
113
mlock (ptr , sz );
114
- #elif defined _WIN32
114
+ #elif defined( _WIN32 )
115
115
VirtualLock (ptr , sz );
116
116
#endif
117
117
}
You can’t perform that action at this time.
0 commit comments