/ Check-in [d54d3b82]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Ignore errors when when calling fsync() on a directory. Ticket #1657. (CVS 3068)
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1:d54d3b82c468b7e6dd39aac6aac56b26b3918c37
User & Date: drh 2006-02-09 23:05:51
Context
2006-02-10
02:27
Add the column_origin_name() etc. APIs. (CVS 3069) check-in: 82f502cd user: danielk1977 tags: trunk
2006-02-09
23:05
Ignore errors when when calling fsync() on a directory. Ticket #1657. (CVS 3068) check-in: d54d3b82 user: drh tags: trunk
22:24
Allow '@' to introduce host parameter names for compatibility with MS SQL Server. Ticket #1671. (CVS 3067) check-in: 0738ef81 user: drh tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to src/os_unix.c.

1056
1057
1058
1059
1060
1061
1062





1063
1064
1065
1066
1067
1068
1069
1070
  if( full_fsync(pFile->h, pFile->fullSync, dataOnly) ){
    return SQLITE_IOERR;
  }
  if( pFile->dirfd>=0 ){
    TRACE2("DIRSYNC %-3d\n", pFile->dirfd);
#ifndef SQLITE_DISABLE_DIRSYNC
    if( full_fsync(pFile->dirfd, pFile->fullSync, 0) ){





        return SQLITE_IOERR;
    }
#endif
    close(pFile->dirfd);  /* Only need to sync once, so close the directory */
    pFile->dirfd = -1;    /* when we are done. */
  }
  return SQLITE_OK;
}







>
>
>
>
>
|







1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
  if( full_fsync(pFile->h, pFile->fullSync, dataOnly) ){
    return SQLITE_IOERR;
  }
  if( pFile->dirfd>=0 ){
    TRACE2("DIRSYNC %-3d\n", pFile->dirfd);
#ifndef SQLITE_DISABLE_DIRSYNC
    if( full_fsync(pFile->dirfd, pFile->fullSync, 0) ){
       /* We have received multiple reports of fsync() returning
       ** errors when applied to directories on certain file systems.
       ** A failed directory sync is not a big deal.  So it seems
       ** better to ignore the error.  Ticket #1657
       */
       /* return SQLITE_IOERR; */
    }
#endif
    close(pFile->dirfd);  /* Only need to sync once, so close the directory */
    pFile->dirfd = -1;    /* when we are done. */
  }
  return SQLITE_OK;
}