mirror of
https://sourceware.org/git/glibc.git
synced 2025-01-03 00:10:10 +00:00
* sysdeps/unix/sysv/linux/sysconf.c (__sysconf):
/proc/sys/kenrel/rtsig_max doesn't exist anymore, use getrlimit instead.
This commit is contained in:
parent
8c4a5f4214
commit
5be0a68819
@ -1,5 +1,9 @@
|
|||||||
2009-02-24 Ulrich Drepper <drepper@redhat.com>
|
2009-02-24 Ulrich Drepper <drepper@redhat.com>
|
||||||
|
|
||||||
|
* sysdeps/unix/sysv/linux/sysconf.c (__sysconf):
|
||||||
|
/proc/sys/kenrel/rtsig_max doesn't exist anymore, use getrlimit
|
||||||
|
instead.
|
||||||
|
|
||||||
* io/sys/stat.h: The lstat functions have been mandatory since 2001.
|
* io/sys/stat.h: The lstat functions have been mandatory since 2001.
|
||||||
|
|
||||||
* time/tzset.c (tzset_internal): Correct parsing of TZ envvar.
|
* time/tzset.c (tzset_internal): Correct parsing of TZ envvar.
|
||||||
|
@ -1,3 +1,8 @@
|
|||||||
|
2009-02-24 Ulrich Drepper <drepper@redhat.com>
|
||||||
|
|
||||||
|
* sysdeps/unix/sysv/linux/bits/posix_opt.h (_BITS_POSIX_OPT_H):
|
||||||
|
Unify name of include protector macro.
|
||||||
|
|
||||||
2009-02-14 SUGIOKA Toshinobu <sugioka@itonet.co.jp>
|
2009-02-14 SUGIOKA Toshinobu <sugioka@itonet.co.jp>
|
||||||
|
|
||||||
* sysdeps/unix/sysv/linux/sh/lowlevellock.S: Define
|
* sysdeps/unix/sysv/linux/sh/lowlevellock.S: Define
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/* Get file-specific information about a file. Linux version.
|
/* Get file-specific information about a file. Linux version.
|
||||||
Copyright (C) 2003, 2004, 2006, 2008 Free Software Foundation, Inc.
|
Copyright (C) 2003, 2004, 2006, 2008, 2009 Free Software Foundation, Inc.
|
||||||
This file is part of the GNU C Library.
|
This file is part of the GNU C Library.
|
||||||
|
|
||||||
The GNU C Library is free software; you can redistribute it and/or
|
The GNU C Library is free software; you can redistribute it and/or
|
||||||
@ -43,6 +43,7 @@ __sysconf (int name)
|
|||||||
|
|
||||||
switch (name)
|
switch (name)
|
||||||
{
|
{
|
||||||
|
struct rlimit rlimit;
|
||||||
#ifdef __NR_clock_getres
|
#ifdef __NR_clock_getres
|
||||||
case _SC_MONOTONIC_CLOCK:
|
case _SC_MONOTONIC_CLOCK:
|
||||||
/* Check using the clock_getres system call. */
|
/* Check using the clock_getres system call. */
|
||||||
@ -84,12 +85,9 @@ __sysconf (int name)
|
|||||||
size. */
|
size. */
|
||||||
if (GLRO(dl_discover_osversion) () >= 0x020617)
|
if (GLRO(dl_discover_osversion) () >= 0x020617)
|
||||||
#endif
|
#endif
|
||||||
{
|
/* Use getrlimit to get the stack limit. */
|
||||||
/* Use getrlimit to get the stack limit. */
|
if (__getrlimit (RLIMIT_STACK, &rlimit) == 0)
|
||||||
struct rlimit rlimit;
|
return MAX (legacy_ARG_MAX, rlimit.rlim_cur / 4);
|
||||||
if (__getrlimit (RLIMIT_STACK, &rlimit) == 0)
|
|
||||||
return MAX (legacy_ARG_MAX, rlimit.rlim_cur / 4);
|
|
||||||
}
|
|
||||||
|
|
||||||
return legacy_ARG_MAX;
|
return legacy_ARG_MAX;
|
||||||
|
|
||||||
@ -100,6 +98,9 @@ __sysconf (int name)
|
|||||||
break;
|
break;
|
||||||
|
|
||||||
case _SC_SIGQUEUE_MAX:
|
case _SC_SIGQUEUE_MAX:
|
||||||
|
if (__getrlimit (RLIMIT_SIGPENDING, &rlimit) == 0)
|
||||||
|
return rlimit.rlim_cur;
|
||||||
|
|
||||||
/* The /proc/sys/kernel/rtsig-max file contains the answer. */
|
/* The /proc/sys/kernel/rtsig-max file contains the answer. */
|
||||||
procfname = "/proc/sys/kernel/rtsig-max";
|
procfname = "/proc/sys/kernel/rtsig-max";
|
||||||
break;
|
break;
|
||||||
|
Loading…
Reference in New Issue
Block a user