Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/usr.bin/tail leave the original errno as it was. don't repor...



details:   https://anonhg.NetBSD.org/src/rev/533b043070a8
branches:  trunk
changeset: 769204:533b043070a8
user:      christos <christos%NetBSD.org@localhost>
date:      Sat Sep 03 10:35:13 2011 +0000

description:
leave the original errno as it was. don't report EFBIG on all mmap failures.

diffstat:

 usr.bin/tail/reverse.c |  5 ++---
 1 files changed, 2 insertions(+), 3 deletions(-)

diffs (26 lines):

diff -r 7b7ce0982147 -r 533b043070a8 usr.bin/tail/reverse.c
--- a/usr.bin/tail/reverse.c    Sat Sep 03 10:28:33 2011 +0000
+++ b/usr.bin/tail/reverse.c    Sat Sep 03 10:35:13 2011 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: reverse.c,v 1.21 2011/09/03 09:02:20 christos Exp $    */
+/*     $NetBSD: reverse.c,v 1.22 2011/09/03 10:35:13 christos Exp $    */
 
 /*-
  * Copyright (c) 1991, 1993
@@ -37,7 +37,7 @@
 #if 0
 static char sccsid[] = "@(#)reverse.c  8.1 (Berkeley) 6/6/93";
 #endif
-__RCSID("$NetBSD: reverse.c,v 1.21 2011/09/03 09:02:20 christos Exp $");
+__RCSID("$NetBSD: reverse.c,v 1.22 2011/09/03 10:35:13 christos Exp $");
 #endif /* not lint */
 
 #include <sys/param.h>
@@ -122,7 +122,6 @@
 
        if ((start = mmap(NULL, (size_t)size, PROT_READ,
            MAP_FILE|MAP_SHARED, fileno(fp), (off_t)0)) == (caddr_t)-1) {
-               errno = EFBIG;
                xerr(0, "%s", fname);
                return;
        }



Home | Main Index | Thread Index | Old Index