1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-11-14 00:22:38 +03:00

Add the SQLITE_FCNTL_FILE_POINTER verb to sqlite3_file_control().

FossilOrigin-Name: 4425b0645d0afebe3172201012d501c6992daa38
This commit is contained in:
drh
2010-11-19 14:37:49 +00:00
parent 38777db5fe
commit 3eb0811457
4 changed files with 36 additions and 11 deletions

View File

@@ -2356,7 +2356,10 @@ int sqlite3_file_control(sqlite3 *db, const char *zDbName, int op, void *pArg){
assert( pPager!=0 );
fd = sqlite3PagerFile(pPager);
assert( fd!=0 );
if( fd->pMethods ){
if( op==SQLITE_FCNTL_FILE_POINTER ){
*(sqlite3_file**)pArg = fd;
rc = SQLITE_OK;
}else if( fd->pMethods ){
rc = sqlite3OsFileControl(fd, op, pArg);
}
sqlite3BtreeLeave(pBtree);