aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorshane <shane@noemail.net>2008-11-13 18:20:43 +0000
committershane <shane@noemail.net>2008-11-13 18:20:43 +0000
commit84ca3837c28248ba1537e3bc4eb2bc6d00fd05d3 (patch)
tree7d2d25877e744d338e6e1e2120d32c078f09d825 /src
parentec21707dd7af9c59773de28106a50460a39c4310 (diff)
downloadsqlite-84ca3837c28248ba1537e3bc4eb2bc6d00fd05d3.tar.gz
sqlite-84ca3837c28248ba1537e3bc4eb2bc6d00fd05d3.zip
Added support for -DSQLITE_NO_SYNC to os_win.c. (CVS 5904)
FossilOrigin-Name: 2649337937077d2dba7cdc7473fcd176aa252a52
Diffstat (limited to 'src')
-rw-r--r--src/os_win.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/os_win.c b/src/os_win.c
index f09b69861..ab797a6e1 100644
--- a/src/os_win.c
+++ b/src/os_win.c
@@ -12,7 +12,7 @@
**
** This file contains code that is specific to windows.
**
-** $Id: os_win.c,v 1.137 2008/11/07 00:06:18 drh Exp $
+** $Id: os_win.c,v 1.138 2008/11/13 18:20:43 shane Exp $
*/
#include "sqliteInt.h"
#if SQLITE_OS_WIN /* This file is used for windows only */
@@ -751,11 +751,18 @@ static int winSync(sqlite3_file *id, int flags){
}
sqlite3_sync_count++;
#endif
+ /* If we compiled with the SQLITE_NO_SYNC flag, then syncing is a
+ ** no-op
+ */
+#ifdef SQLITE_NO_SYNC
+ return SQLITE_OK;
+#else
if( FlushFileBuffers(pFile->h) ){
return SQLITE_OK;
}else{
return SQLITE_IOERR;
}
+#endif
}
/*