1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-11-12 13:01:09 +03:00

Rig the unix backend to use fdatasync() by default, without having to set the

HAVE_FDATASYNC macro.  Systems that do not support fdatasync() can be compiled
using -Dfdatasync=fsync. (CVS 6368)

FossilOrigin-Name: a331562727be465874a66c2c1d15ee070f96f7e0
This commit is contained in:
drh
2009-03-21 14:56:52 +00:00
parent 0b647ffd47
commit 4a7384a25f
3 changed files with 11 additions and 11 deletions

View File

@@ -43,7 +43,7 @@
** * Definitions of sqlite3_vfs objects for all locking methods
** plus implementations of sqlite3_os_init() and sqlite3_os_end().
**
** $Id: os_unix.c,v 1.243 2009/03/21 14:41:04 drh Exp $
** $Id: os_unix.c,v 1.244 2009/03/21 14:56:52 drh Exp $
*/
#include "sqliteInt.h"
#if SQLITE_OS_UNIX /* This file is used on unix only */
@@ -2824,10 +2824,10 @@ int sqlite3_fullsync_count = 0;
#endif
/*
** Use the fdatasync() API only if the HAVE_FDATASYNC macro is defined.
** Otherwise use fsync() in its place.
** We assume that most systems these days support fdatasync(). Those
** machines that do not can define -Dfdatasync=fsync.
*/
#ifndef HAVE_FDATASYNC
#if 0
# define fdatasync fsync
#endif