mirror of
https://github.com/sqlite/sqlite.git
synced 2025-11-12 13:01:09 +03:00
Ignore the value of SQLITE_FCNTL_CHUNK_SIZE if it is negative.
FossilOrigin-Name: 1b08fef9451f4d59148548faed115d1a5d0bcd98
This commit is contained in:
@@ -3421,7 +3421,7 @@ static int unixTruncate(sqlite3_file *id, i64 nByte){
|
||||
** actual file size after the operation may be larger than the requested
|
||||
** size).
|
||||
*/
|
||||
if( pFile->szChunk ){
|
||||
if( pFile->szChunk>0 ){
|
||||
nByte = ((nByte + pFile->szChunk - 1)/pFile->szChunk) * pFile->szChunk;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user