From b5e9addd22eabcce2e017947a3b5e8569ca6500a Mon Sep 17 00:00:00 2001 From: rmind Date: Sat, 26 Jan 2008 17:55:29 +0000 Subject: sched_setparam: fix the case when incorrect (according to the class) in-kernel priority is used. Reported by . Minor fixes for scheduling calls to conform the POSIX: - If pid is equal to zero, use the calling process; - In case of permission problem, return EPERM instead of EACESS; - sched_setscheduler() should return previously used policy; - pthread_* calls should return the error code or zero; Should fix the namespace problems (and builds of some packages): - Move cpuset_t defintion from pset.h to sched.h; - Remove the #include of pset.h in pthread.h; --- lib/libc/gen/sysconf.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'lib/libc') diff --git a/lib/libc/gen/sysconf.c b/lib/libc/gen/sysconf.c index 4f8e1459a26..b9180b20a5a 100644 --- a/lib/libc/gen/sysconf.c +++ b/lib/libc/gen/sysconf.c @@ -1,4 +1,4 @@ -/* $NetBSD: sysconf.c,v 1.26 2008/01/15 03:37:14 rmind Exp $ */ +/* $NetBSD: sysconf.c,v 1.27 2008/01/26 17:55:30 rmind Exp $ */ /*- * Copyright (c) 1993 @@ -37,7 +37,7 @@ #if 0 static char sccsid[] = "@(#)sysconf.c 8.2 (Berkeley) 3/20/94"; #else -__RCSID("$NetBSD: sysconf.c,v 1.26 2008/01/15 03:37:14 rmind Exp $"); +__RCSID("$NetBSD: sysconf.c,v 1.27 2008/01/26 17:55:30 rmind Exp $"); #endif #endif /* LIBC_SCCS and not lint */ @@ -357,7 +357,7 @@ yesno: if (sysctl(mib, mib_len, &value, &len, NULL, 0) == -1) /* Native */ case _SC_SCHED_RT_TS: - if (sysctlgetmibinfo("kern.sched.rt_ts", &mib[0], &mib_len, + if (sysctlgetmibinfo("kern.sched.rtts", &mib[0], &mib_len, NULL, NULL, NULL, SYSCTL_VERSION)) return -1; break; -- cgit