aboutsummaryrefslogtreecommitdiff
path: root/src/os.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/os.c')
-rw-r--r--src/os.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/os.c b/src/os.c
index 6671d0ae3..10e40a079 100644
--- a/src/os.c
+++ b/src/os.c
@@ -115,7 +115,13 @@ int sqlite3OsDelete(sqlite3_vfs *pVfs, const char *zPath, int dirSync){
return pVfs->xDelete(pVfs, zPath, dirSync);
}
int sqlite3OsAccess(sqlite3_vfs *pVfs, const char *zPath, int flags){
- int rc = pVfs->xAccess(pVfs, zPath, flags);
+ int rc;
+#ifdef SQLITE_TEST
+ void *pTstAlloc = sqlite3_malloc(10);
+ if (!pTstAlloc) return -1;
+ sqlite3_free(pTstAlloc);
+#endif
+ rc = pVfs->xAccess(pVfs, zPath, flags);
assert( rc==0 || rc==1 );
return rc;
}