TT#24097 Localize %ENV variable assignments

While these instances are a bit pointless as they are assigned on the
file scope, and this is something that should be allowed by perlcritic.
Let's just do this, which does no harm, so that we can catch other
problematic cases.

Change-Id: I674b1374a62fa976e20a3fedf356ae6d4848a796
changes/11/16711/3
Guillem Jover 8 years ago
parent 301af4a2e9
commit 0c728b2041

@ -46,7 +46,7 @@ GetOptions(
($IP || $IPV6) or die("at least one of --local-ip or --local-ipv6 must be given");
$SIG{ALRM} = sub { print "alarm!\n"; };
local $SIG{ALRM} = sub { print "alarm!\n"; };
setrlimit(RLIMIT_NOFILE, 8000, 8000);
$PROTOS and $PROTOS = [split(/\s*[,;:]+\s*/, $PROTOS)];

@ -23,7 +23,7 @@ GetOptions(
($IP || $IPV6) or die("at least one of --local-ip or --local-ipv6 must be given");
$SIG{ALRM} = sub { print "alarm!\n"; };
local $SIG{ALRM} = sub { print "alarm!\n"; };
setrlimit(RLIMIT_NOFILE, 8000, 8000);
my @chrs = ('a' .. 'z', 'A' .. 'Z', '0' .. '9');

Loading…
Cancel
Save