Skip to content

Commit 493212f

Browse files
committed
Revert "Use O_LARGEFILE when creating log files on non-APPLE platforms." (fix #8)
This reverts commit eacabaf. Configuring large file system (LFS) support is a build system issue and should not be tackled by code changes. O_LARGEFILE is a GNU extension and is not supported on all platforms. If still required, the `-D_FILE_OFFSET_BITS=64` should be added to the compiler command line via CMake. See http://man7.org/linux/man-pages/man7/feature_test_macros.7.html.
1 parent 71b1456 commit 493212f

File tree

1 file changed

+0
-8
lines changed

1 file changed

+0
-8
lines changed

src/FileAppender.cpp

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -30,11 +30,7 @@ namespace log4cpp {
3030
mode_t mode) :
3131
LayoutAppender(name),
3232
_fileName(fileName),
33-
#ifdef __APPLE__
3433
_flags(O_CREAT | O_APPEND | O_WRONLY),
35-
#else
36-
_flags(O_CREAT | O_APPEND | O_WRONLY | O_LARGEFILE),
37-
#endif
3834
_mode(mode) {
3935
if (!append)
4036
_flags |= O_TRUNC;
@@ -45,11 +41,7 @@ namespace log4cpp {
4541
LayoutAppender(name),
4642
_fileName(""),
4743
_fd(fd),
48-
#ifdef __APPLE__
4944
_flags(O_CREAT | O_APPEND | O_WRONLY),
50-
#else
51-
_flags(O_CREAT | O_APPEND | O_WRONLY | O_LARGEFILE),
52-
#endif
5345
_mode(00644) {
5446
}
5547

0 commit comments

Comments
 (0)