This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Add GETENV_LOCK
authorKarl Williamson <khw@cpan.org>
Tue, 1 Dec 2020 14:44:18 +0000 (07:44 -0700)
committerKarl Williamson <khw@cpan.org>
Sun, 20 Dec 2020 05:00:30 +0000 (22:00 -0700)
commit35bcf7ffa2bfeab79ab7b4eb0d35f462775b54d2
treefeffc93e76297c539b0bc9985c2a88d626caf7e5
parent9d228af78ad17dabb51f9059d215cc88c059a22a
Add GETENV_LOCK

get_env() needs to lock other threads from writing to the environment
while it is executing.  It may need to have an exclusive lock if those
threads can clobber its buffer before it gets a chance to save them.
The previous commit has added a Configure probe which tells us if that
is the case.  This commit uses it to select which type of mutex to use.
inline.h
perl.h