Source-Changes-HG archive

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

[src/trunk]: src/usr.bin/xinstall don't bitch if madvise returns EOPNOTSUPP



details:   https://anonhg.NetBSD.org/src/rev/8a0c398ba45b
branches:  trunk
changeset: 480537:8a0c398ba45b
user:      christos <christos%NetBSD.org@localhost>
date:      Sat Jan 15 01:10:12 2000 +0000

description:
don't bitch if madvise returns EOPNOTSUPP

diffstat:

 usr.bin/xinstall/xinstall.c |  7 ++++---
 1 files changed, 4 insertions(+), 3 deletions(-)

diffs (28 lines):

diff -r 1064e74fd3c3 -r 8a0c398ba45b usr.bin/xinstall/xinstall.c
--- a/usr.bin/xinstall/xinstall.c       Sat Jan 15 01:03:45 2000 +0000
+++ b/usr.bin/xinstall/xinstall.c       Sat Jan 15 01:10:12 2000 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: xinstall.c,v 1.38 1999/08/01 05:02:06 sommerfeld Exp $ */
+/*     $NetBSD: xinstall.c,v 1.39 2000/01/15 01:10:12 christos Exp $   */
 
 /*
  * Copyright (c) 1987, 1993
@@ -43,7 +43,7 @@
 #if 0
 static char sccsid[] = "@(#)xinstall.c 8.1 (Berkeley) 7/21/93";
 #else
-__RCSID("$NetBSD: xinstall.c,v 1.38 1999/08/01 05:02:06 sommerfeld Exp $");
+__RCSID("$NetBSD: xinstall.c,v 1.39 2000/01/15 01:10:12 christos Exp $");
 #endif
 #endif /* not lint */
 
@@ -530,7 +530,8 @@
                                (void)unlink(to_name);
                                errx(1, "%s: %s", from_name, strerror(serrno));
                        }
-                       if (madvise(p, (size_t)size, MADV_SEQUENTIAL) == -1)
+                       if (madvise(p, (size_t)size, MADV_SEQUENTIAL) == -1
+                           && errno != EOPNOTSUPP)
                                warnx("madvise: %s", strerror(errno));
 
                        if (write(to_fd, p, size) != size) {



Home | Main Index | Thread Index | Old Index