diff options
| author | Dag-Erling Smørgrav <des@FreeBSD.org> | 2007-05-23 12:09:33 +0000 |
|---|---|---|
| committer | Dag-Erling Smørgrav <des@FreeBSD.org> | 2007-05-23 12:09:33 +0000 |
| commit | 4b5b992bbac261a7c5cfc9c350dc9c644dd3a383 (patch) | |
| tree | f72a92c9ae8d09b20cb8373ea29fdcac39ebecc7 /lib/libutil/flopen.c | |
| parent | 64c40cdcb0c1a583eeaf558a0b105d93315a2fb0 (diff) | |
Notes
Diffstat (limited to 'lib/libutil/flopen.c')
| -rw-r--r-- | lib/libutil/flopen.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/libutil/flopen.c b/lib/libutil/flopen.c index b99055ea7bc1..23742f7ceec7 100644 --- a/lib/libutil/flopen.c +++ b/lib/libutil/flopen.c @@ -41,7 +41,7 @@ __FBSDID("$FreeBSD$"); int flopen(const char *path, int flags, ...) { - int fd, operation, serrno, truncate; + int fd, operation, serrno, trunc; struct stat sb, fsb; mode_t mode; @@ -62,7 +62,7 @@ flopen(const char *path, int flags, ...) if (flags & O_NONBLOCK) operation |= LOCK_NB; - truncate = (flags & O_TRUNC); + trunc = (flags & O_TRUNC); flags &= ~O_TRUNC; for (;;) { @@ -94,7 +94,7 @@ flopen(const char *path, int flags, ...) close(fd); continue; } - if (truncate && ftruncate(fd, 0) != 0) { + if (trunc && ftruncate(fd, 0) != 0) { /* can't happen [tm] */ serrno = errno; close(fd); |
