summaryrefslogtreecommitdiffstats
path: root/usr.bin/tail
diff options
context:
space:
mode:
authorache <ache@FreeBSD.org>2001-03-26 19:36:27 +0000
committerache <ache@FreeBSD.org>2001-03-26 19:36:27 +0000
commit5b94e50e9a2d4249803cf2d0b4936ec92e4e3761 (patch)
tree00c3a6e07e5ae4181e38b12352b5db7e9cee1b24 /usr.bin/tail
parent36ca6097d17dd860b4d78581d593936c9cf687c4 (diff)
downloadFreeBSD-src-5b94e50e9a2d4249803cf2d0b4936ec92e4e3761.zip
FreeBSD-src-5b94e50e9a2d4249803cf2d0b4936ec92e4e3761.tar.gz
Treat mmap() error as fatal too, i.e. do exit(1) instead of return
Diffstat (limited to 'usr.bin/tail')
-rw-r--r--usr.bin/tail/forward.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/usr.bin/tail/forward.c b/usr.bin/tail/forward.c
index f63b410..023f941 100644
--- a/usr.bin/tail/forward.c
+++ b/usr.bin/tail/forward.c
@@ -290,7 +290,7 @@ rlines(fp, off, sbp)
if ((start = mmap(NULL, (size_t)size,
PROT_READ, MAP_SHARED, fileno(fp), (off_t)0)) == MAP_FAILED) {
ierr();
- return;
+ exit(1);
}
/* Last char is special, ignore whether newline or not. */
OpenPOWER on IntegriCloud