mirror of
https://github.com/sqlite/sqlite.git
synced 2025-08-05 15:55:57 +03:00
Allow the xAccess method in the VFS to return -1 to signal an I/O
error, and in particular an SQLITE_IOERR_NOMEM. (CVS 4925) FossilOrigin-Name: 3cb704c4c439425781644b1b653b7e50f02fd91e
This commit is contained in:
8
src/os.c
8
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;
|
||||
}
|
||||
|
Reference in New Issue
Block a user