libcsu: Assign environment when environ is NULL
authorJohn Marino <draco@marino.st>
Sun, 10 Feb 2013 11:32:58 +0000 (12:32 +0100)
committerJohn Marino <draco@marino.st>
Sun, 10 Feb 2013 11:50:10 +0000 (12:50 +0100)
commita834075aac70cf3ca01ed23d8220fb556730fe06
treea032d5d37ee96446b8e2e5cde98497b42c5b208c
parent58e4c0cfdbaba48eb282aa8fb3fe3793de5228c6
libcsu: Assign environment when environ is NULL

Preloaded libraries can change the environment.  The current logic will
unconditionally reassign the environment, undoing any previous
customization.  This change preserves the previous customization.

Taken-from: FreeBSD SVN 245133 (07 Jan 2013)
lib/csu/common/initfini.c
lib/csu/i386/crt1_c.c
lib/csu/x86_64/crt1.c