Source-Changes-HG archive

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

[src/netbsd-1-5]: src/usr.bin/renice Pull up rev. 1.8 (approved by thorpej):



details:   https://anonhg.NetBSD.org/src/rev/279021309c29
branches:  netbsd-1-5
changeset: 489229:279021309c29
user:      kleink <kleink%NetBSD.org@localhost>
date:      Wed Aug 23 19:49:21 2000 +0000

description:
Pull up rev. 1.8 (approved by thorpej):
Deal with a current priority of -1; from Takahiro Kambe in PR bin/10227.

diffstat:

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

diffs (28 lines):

diff -r 838584cd4a12 -r 279021309c29 usr.bin/renice/renice.c
--- a/usr.bin/renice/renice.c   Wed Aug 23 15:02:20 2000 +0000
+++ b/usr.bin/renice/renice.c   Wed Aug 23 19:49:21 2000 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: renice.c,v 1.6 1998/12/19 21:07:12 christos Exp $      */
+/*     $NetBSD: renice.c,v 1.6.10.1 2000/08/23 19:49:21 kleink Exp $   */
 
 /*
  * Copyright (c) 1983, 1989, 1993
@@ -41,7 +41,7 @@
 
 #ifndef lint
 /*static char sccsid[] = "from: @(#)renice.c   8.1 (Berkeley) 6/9/93";*/
-__RCSID("$NetBSD: renice.c,v 1.6 1998/12/19 21:07:12 christos Exp $");
+__RCSID("$NetBSD: renice.c,v 1.6.10.1 2000/08/23 19:49:21 kleink Exp $");
 #endif /* not lint */
 
 #include <sys/types.h>
@@ -148,7 +148,8 @@
 {
        int oldprio;
 
-       if ((oldprio = getpriority(which, who)) == -1) {
+       errno = 0;
+       if ((oldprio = getpriority(which, who)) == -1 && errno != 0) {
                warn("%d: getpriority", who);
                return (1);
        }



Home | Main Index | Thread Index | Old Index