summaryrefslogtreecommitdiffstats
path: root/lib/libc/stdio/stdio.c
diff options
context:
space:
mode:
authorngie <ngie@FreeBSD.org>2015-11-16 02:00:12 +0000
committerngie <ngie@FreeBSD.org>2015-11-16 02:00:12 +0000
commitfd9367ff35d3ef67f52f8612ba6df3c487b90f4d (patch)
tree68c676723f5f9cd1d66be903cfdce6b37dcc3719 /lib/libc/stdio/stdio.c
parent3d588fbc9bc229fdd93d6aaf6340583c2bcaca9f (diff)
parentb708fe19431dfeacfe97dbc276190934bd53b483 (diff)
downloadFreeBSD-src-fd9367ff35d3ef67f52f8612ba6df3c487b90f4d.zip
FreeBSD-src-fd9367ff35d3ef67f52f8612ba6df3c487b90f4d.tar.gz
MFhead @ r290899
Diffstat (limited to 'lib/libc/stdio/stdio.c')
-rw-r--r--lib/libc/stdio/stdio.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/libc/stdio/stdio.c b/lib/libc/stdio/stdio.c
index 44ee0ab..5d6fb9a 100644
--- a/lib/libc/stdio/stdio.c
+++ b/lib/libc/stdio/stdio.c
@@ -117,7 +117,7 @@ _swrite(FILE *fp, char const *buf, int n)
ret = (*fp->_write)(fp->_cookie, buf, n);
/* __SOFF removed even on success in case O_APPEND mode is set. */
if (ret >= 0) {
- if ((fp->_flags & (__SAPP|__SOFF)) == (__SAPP|__SOFF) &&
+ if ((fp->_flags & __SOFF) && !(fp->_flags2 & __S2OAP) &&
fp->_offset <= OFF_MAX - ret)
fp->_offset += ret;
else
OpenPOWER on IntegriCloud