Bug 9758

Summary: RTLD_DEEPBIND causes separate NULL `environ'
Product: glibc Reporter: Jan Kratochvil <jan>
Component: dynamic-linkAssignee: Not yet assigned to anyone <unassigned>
Status: NEW ---    
Severity: minor CC: glibc-bugs, parky
Priority: P3 Flags: fweimer: security-
Version: unspecified   
Target Milestone: ---   
Host: x86_64-unknown-linux-gnu Target:
Build: Last reconfirmed:
Attachments: Demo of the problem (deepbind-environ).

Description Jan Kratochvil 2009-01-17 22:35:12 UTC
After some debugging ( https://bugzilla.redhat.com/show_bug.cgi?id=480504 )
found out a use of RTLD_DEEPBIND will cause NULL `environ' in the loaded library.

This is IMO a generally unexpected behavior and either `environ' should be an
exception of being shared despite RTLD_DEEPBIND or at least the man page could
make a note of it.

Tested on: Fedora glibc-2.9-3.x86_64
Comment 1 Jan Kratochvil 2009-01-17 22:36:12 UTC
Created attachment 3670 [details]
Demo of the problem (deepbind-environ).
Comment 2 Andreas Schwab 2017-06-28 14:10:19 UTC
This works on architectures that don't use COPY relocations.