1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-10-27 08:52:26 +03:00

Make sure the rc variable in OsWrite of os_win.c is always initialized.

Also assert that the amt parameter is always greater than zero.
Ticket #1094. (CVS 2309)

FossilOrigin-Name: 4b399ae7791288e5d44f90da530908d9ca77ff4b
This commit is contained in:
drh
2005-02-03 00:29:47 +00:00
parent 99b214d28e
commit 4c7f941cfc
6 changed files with 34 additions and 22 deletions

View File

@@ -661,6 +661,7 @@ int sqlite3OsRead(OsFile *id, void *pBuf, int amt){
int sqlite3OsWrite(OsFile *id, const void *pBuf, int amt){
int wrote = 0;
assert( id->isOpen );
assert( amt>0 );
SimulateIOError(SQLITE_IOERR);
SimulateDiskfullError;
TIMER_START;