summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--libutil/flopen.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libutil/flopen.c b/libutil/flopen.c
index 92254cc..b99055e 100644
--- a/libutil/flopen.c
+++ b/libutil/flopen.c
@@ -63,7 +63,7 @@ flopen(const char *path, int flags, ...)
operation |= LOCK_NB;
truncate = (flags & O_TRUNC);
- flags |= ~O_TRUNC;
+ flags &= ~O_TRUNC;
for (;;) {
if ((fd = open(path, flags, mode)) == -1)