mirror of
https://github.com/sqlite/sqlite.git
synced 2025-11-12 13:01:09 +03:00
Add new OS file method to return the sector-size of the underlying storage: sqlite3OsSectorSize() (CVS 3700)
FossilOrigin-Name: 5752d84d374205e011d49b0221d6237967fe0743
This commit is contained in:
@@ -650,6 +650,13 @@ static int asyncCheckReservedLock(OsFile *id){
|
||||
return rc>SHARED_LOCK;
|
||||
}
|
||||
|
||||
static int asyncSectorSize(OsFile *id){
|
||||
/* TODO: This is tricky to implement, as this backend might not have
|
||||
** an open file handle at this point.
|
||||
*/
|
||||
return 512;
|
||||
}
|
||||
|
||||
/*
|
||||
** This is broken. But sqlite3OsLockState() is only used for testing anyway.
|
||||
*/
|
||||
@@ -697,7 +704,8 @@ static int asyncOpenFile(
|
||||
asyncLock,
|
||||
asyncUnlock,
|
||||
asyncLockState,
|
||||
asyncCheckReservedLock
|
||||
asyncCheckReservedLock,
|
||||
asyncSectorSize,
|
||||
};
|
||||
|
||||
if( openForWriting && SQLITE_ASYNC_TWO_FILEHANDLES ){
|
||||
|
||||
Reference in New Issue
Block a user