1
0
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:
danielk1977
2007-03-19 05:54:48 +00:00
parent 8d3921772f
commit b472117c11
12 changed files with 64 additions and 29 deletions

View File

@@ -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 ){