develooper Front page | perl.perl5.porters | Postings from February 2020

"require" change of behavior in 5.16 or slightly before?

Thread Next
From:
Philip Prindeville
Date:
February 19, 2020 21:46
Subject:
"require" change of behavior in 5.16 or slightly before?
Message ID:
B218CB76-A0F9-4412-BBDA-43641595D415@redfish-solutions.com
Hi,

I have some build scripts that used to work in perl-5.10 and when we updated to perl-5.16 one in particular broke badly.

It does a:

require $config_file;

and two observations: (1) if $config_file is an absolute path, it no longer finds the file (I can see from a security standpoint that not being able to include arbitrary files anywhere on the system might be good…), and (2) if I change that too “… || die …” then the die doesn’t happen.

Were there changes along the way to how “require” behaves?  And what’s the workaround?

Thanks,

-Philip

Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About