diff options
author | bapt <bapt@FreeBSD.org> | 2015-10-28 11:58:18 +0000 |
---|---|---|
committer | bapt <bapt@FreeBSD.org> | 2015-10-28 11:58:18 +0000 |
commit | c21ffb8d6aca32c9584cfa072f309a5890a21aea (patch) | |
tree | c13556877cfa7b8f6941e8141a6801cf91e72840 /lib/libc/stdio/fopen.c | |
parent | ec14b01dd8898deebe0427357d842721add8e34c (diff) | |
parent | 39fb527bf90f6a5cb03d93bd49c310bbca016a45 (diff) | |
download | FreeBSD-src-c21ffb8d6aca32c9584cfa072f309a5890a21aea.zip FreeBSD-src-c21ffb8d6aca32c9584cfa072f309a5890a21aea.tar.gz |
Merge from head
Sponsored by: Gandi.net
Diffstat (limited to 'lib/libc/stdio/fopen.c')
-rw-r--r-- | lib/libc/stdio/fopen.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/libc/stdio/fopen.c b/lib/libc/stdio/fopen.c index b08e336..b26f637 100644 --- a/lib/libc/stdio/fopen.c +++ b/lib/libc/stdio/fopen.c @@ -91,7 +91,10 @@ fopen(const char * __restrict file, const char * __restrict mode) * we can do about this. (We could set __SAPP and check in * fseek and ftell.) */ - if (oflags & O_APPEND) + if (oflags & O_APPEND) { + /* XXX: Reuse __SALC for O_APPEND. */ + fp->_flags |= __SALC; (void)_sseek(fp, (fpos_t)0, SEEK_END); + } return (fp); } |