diff options
author | Mathias Stearn <mathias@10gen.com> | 2011-08-09 15:39:35 -0400 |
---|---|---|
committer | Mathias Stearn <mathias@10gen.com> | 2011-08-09 15:41:01 -0400 |
commit | 7cad9757de992d4db6f6e991dedd970d9a17d0c0 (patch) | |
tree | 2ea2feeb560ade734113446cfbb8e1a93bbf2ffe | |
parent | f86448f78b656f082ba6905747dca172ad78bec9 (diff) | |
download | mongo-7cad9757de992d4db6f6e991dedd970d9a17d0c0.tar.gz |
Don't need to call lseek if we won't do fadvise (was getting unused var warning)
-rw-r--r-- | util/logfile.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/util/logfile.cpp b/util/logfile.cpp index 109c7dc1008..609edb8fe2d 100644 --- a/util/logfile.cpp +++ b/util/logfile.cpp @@ -170,7 +170,9 @@ namespace mongo { } void LogFile::synchronousAppend(const void *b, size_t len) { +#ifdef POSIX_FADV_DONTNEED const off_t pos = lseek(_fd, 0, SEEK_CUR); // doesn't actually seek +#endif const char *buf = (char *) b; assert(_fd); |