This is the mail archive of the
glibc-bugs@sourceware.org
mailing list for the glibc project.
[Bug libc/22648] New: getrlimit/setrlimit with RLIM_INFINITY broken on alpha
- From: "aurelien at aurel32 dot net" <sourceware-bugzilla at sourceware dot org>
- To: glibc-bugs at sourceware dot org
- Date: Fri, 29 Dec 2017 11:20:43 +0000
- Subject: [Bug libc/22648] New: getrlimit/setrlimit with RLIM_INFINITY broken on alpha
- Auto-submitted: auto-generated
https://sourceware.org/bugzilla/show_bug.cgi?id=22648
Bug ID: 22648
Summary: getrlimit/setrlimit with RLIM_INFINITY broken on alpha
Product: glibc
Version: 2.25
Status: NEW
Severity: normal
Priority: P2
Component: libc
Assignee: aurelien at aurel32 dot net
Reporter: aurelien at aurel32 dot net
CC: drepper.fsp at gmail dot com
Target Milestone: ---
Host: alpha-linux-gnu
Target: alpha-linux-gnu
Build: alpha-linux-gnu
Since commit 045c13d185 ("Consolidate Linux setrlimit and getrlimit
implementation") which is in glibc 2.25, the getrlimit and setrlimit functions
are broken when used with RLIM_INFINITY on alpha. The commit changed the
syscalls behind these functions from getrlimit/setrlimit to prlimit64.
RLIM_INFINITY is not represented the same way in these syscalls on alpha. The
getrlimit/setrlimit syscalls use the same definition than the GNU libc, that is
0x7fffffffffffffff while prlimit64 uses a standard value across all
architectures which is 0xffffffffffffffff.
The commit therefore broke the getrlimit/setrlimit functions on alpha, and is
the reason why dozens of the glibc tests abort with:
allocatestack.c:480: allocate_stack: Assertion `size != 0' failed.
This assertion is also observed in at least ocaml and erlang.
The fix is to add a wrapper function like it has been done on mips in the past.
I'll post a patch on the mailing list.
--
You are receiving this mail because:
You are on the CC list for the bug.