aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRoland McGrath <roland@gnu.org>1995-11-01 10:00:20 +0000
committerRoland McGrath <roland@gnu.org>1995-11-01 10:00:20 +0000
commit80b55d320bae6743130701af3b5c395d21ce748d (patch)
tree6b0178179f972b1d02e7ada40c1ee0b1312b77b8
parent3bbceb1287e3df7eb75e7a9852278d4eb9d33a00 (diff)
downloadglibc-80b55d320bae6743130701af3b5c395d21ce748d.tar
glibc-80b55d320bae6743130701af3b5c395d21ce748d.tar.gz
glibc-80b55d320bae6743130701af3b5c395d21ce748d.tar.bz2
glibc-80b55d320bae6743130701af3b5c395d21ce748d.zip
* sysdeps/mach/hurd/getpriority.c (getpriority): Passcvs/libc-951102cvs/libc-951101
PI_FETCH_TASKINFO to proc_getprocinfo and through _hurd_priority_which_map. * sysdeps/mach/hurd/setpriority.c (setpriority): Pass new arg to _hurd_priority_which_map. * hurd/hurdprio.c (_hurd_priority_which_map): New arg PI_FLAGS, passed through to proc_getprocinfo RPC. * hurd/hurd/resource.h: Add PI_FLAGS arg in decl.
-rw-r--r--ChangeLog10
-rw-r--r--hurd/hurd/resource.h10
-rw-r--r--hurd/hurdprio.c6
-rw-r--r--posix/regex.c3
-rw-r--r--sysdeps/mach/hurd/getpriority.c9
-rw-r--r--sysdeps/mach/hurd/setpriority.c4
6 files changed, 29 insertions, 13 deletions
diff --git a/ChangeLog b/ChangeLog
index f7798649f8..9e49498afe 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,15 @@
Tue Oct 31 00:07:29 1995 Roland McGrath <roland@churchy.gnu.ai.mit.edu>
+ * sysdeps/mach/hurd/getpriority.c (getpriority): Pass
+ PI_FETCH_TASKINFO to proc_getprocinfo and through
+ _hurd_priority_which_map.
+
+ * sysdeps/mach/hurd/setpriority.c (setpriority): Pass new arg to
+ _hurd_priority_which_map.
+ * hurd/hurdprio.c (_hurd_priority_which_map): New arg PI_FLAGS,
+ passed through to proc_getprocinfo RPC.
+ * hurd/hurd/resource.h: Add PI_FLAGS arg in decl.
+
* sysdeps/mach/hurd/group_member.c: New file.
* sysdeps/generic/group_member.c: New file.
diff --git a/hurd/hurd/resource.h b/hurd/hurd/resource.h
index ad2a61ab42..042df05008 100644
--- a/hurd/hurd/resource.h
+++ b/hurd/hurd/resource.h
@@ -1,5 +1,5 @@
/* Resource limits for the Hurd.
-Copyright (C) 1994 Free Software Foundation, Inc.
+Copyright (C) 1994, 1995 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
@@ -33,11 +33,13 @@ extern struct mutex _hurd_rlimit_lock; /* Locks _hurd_rlimits. */
/* Helper function for getpriority and setpriority. Maps FN over all the
processes specified by WHICH and WHO. PI is non-null if a
proc_getprocinfo was already done; FN may use *PI arbitrarily, it is
- reset on the next call. Returns FN's result the first time it returns
- nonzero. If FN never returns nonzero, this returns zero. */
+ reset on the next call; PI_FLAGS is passed to proc_getprocinfo. Returns
+ FN's result the first time it returns nonzero. If FN never returns
+ nonzero, this returns zero. */
extern error_t _hurd_priority_which_map (enum __priority_which which, int who,
error_t (*fn) (pid_t pid,
- struct procinfo *pi));
+ struct procinfo *pi),
+ int pi_flags);
/* Convert between Mach priority values and the priority
values used by getpriority, setpriority, and nice. */
diff --git a/hurd/hurdprio.c b/hurd/hurdprio.c
index 8bad2563fb..9360738988 100644
--- a/hurd/hurdprio.c
+++ b/hurd/hurdprio.c
@@ -1,5 +1,5 @@
/* Support code for dealing with priorities in the Hurd.
-Copyright (C) 1994 Free Software Foundation, Inc.
+Copyright (C) 1994, 1995 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
@@ -22,7 +22,8 @@ Cambridge, MA 02139, USA. */
error_t
_hurd_priority_which_map (enum __priority_which which, int who,
- error_t (*function) (pid_t, struct procinfo *))
+ error_t (*function) (pid_t, struct procinfo *),
+ int pi_flags)
{
mach_msg_type_number_t npids = 64, i;
pid_t pidbuf[npids], *pids;
@@ -59,6 +60,7 @@ _hurd_priority_which_map (enum __priority_which which, int who,
int *oldpi = pi;
mach_msg_type_number_t oldpisize = pisize;
if (err = __USEPORT (PROC, __proc_getprocinfo (port, pids[i],
+ pi_flags,
&pi, &pisize)))
continue;
if (pi != oldpi && oldpi != pibuf)
diff --git a/posix/regex.c b/posix/regex.c
index f1db89adf6..3ca7bb267d 100644
--- a/posix/regex.c
+++ b/posix/regex.c
@@ -28,6 +28,7 @@ Cambridge, MA 02139, USA. */
#pragma alloca
#endif
+#undef _GNU_SOURCE
#define _GNU_SOURCE
#ifdef HAVE_CONFIG_H
@@ -1003,7 +1004,7 @@ static const char *re_error_msgid[] =
This is a variable only so users of regex can assign to it; we never
change it ourselves. */
#if defined (MATCH_MAY_ALLOCATE)
-int re_max_failures = 200000;
+int re_max_failures = 20000;
#else
int re_max_failures = 2000;
#endif
diff --git a/sysdeps/mach/hurd/getpriority.c b/sysdeps/mach/hurd/getpriority.c
index 5b24ce23f8..933592fe8e 100644
--- a/sysdeps/mach/hurd/getpriority.c
+++ b/sysdeps/mach/hurd/getpriority.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 1994 Free Software Foundation, Inc.
+/* Copyright (C) 1994, 1995 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
@@ -41,8 +41,8 @@ getpriority (enum __priority_which which, int who)
{
int *oldpi = pi;
unsigned int oldpisize = pisize;
- onerr = __USEPORT (PROC, __proc_getprocinfo (port,
- pid,
+ onerr = __USEPORT (PROC, __proc_getprocinfo (port, pid,
+ PI_FETCH_TASKINFO,
&pi, &pisize));
if (pi != oldpi && oldpi != pibuf)
/* Old buffer from last call was not reused; free it. */
@@ -56,7 +56,8 @@ getpriority (enum __priority_which which, int who)
}
onerr = 0;
- err = _hurd_priority_which_map (which, who, getonepriority);
+ err = _hurd_priority_which_map (which, who,
+ getonepriority, PI_FETCH_TASKINFO);
if (pi != pibuf)
__vm_deallocate (__mach_task_self (),
diff --git a/sysdeps/mach/hurd/setpriority.c b/sysdeps/mach/hurd/setpriority.c
index 644bfdf6fe..4d2e3f3591 100644
--- a/sysdeps/mach/hurd/setpriority.c
+++ b/sysdeps/mach/hurd/setpriority.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 1994 Free Software Foundation, Inc.
+/* Copyright (C) 1994, 1995 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
@@ -67,7 +67,7 @@ setpriority (enum __priority_which which, int who, int prio)
npids = ntasks = nwin = nperm = nacces = 0;
pidloser = priloser = 0;
- err = _hurd_priority_which_map (which, who, setonepriority);
+ err = _hurd_priority_which_map (which, who, setonepriority, 0);
if (!err && npids == 0)
/* No error, but no pids found. */