mirror of
https://git.tartarus.org/simon/putty.git
synced 2025-01-09 17:38:00 +00:00
Fix a Perl warning when mkfiles.pl gets bad input.
If you forget the '+' at the start of a continuation line with only one word on it, then Perl would test $_[1] before checking that it even existed to test. The test would give the right answer anyway, but the warning was annoying.
This commit is contained in:
parent
1bed56cf57
commit
1a02274272
@ -122,12 +122,12 @@ while (<IN>) {
|
||||
$listref = $lastlistref;
|
||||
$prog = undef;
|
||||
die "$.: unexpected + line\n" if !defined $lastlistref;
|
||||
} elsif ($_[1] eq "=") {
|
||||
} elsif ($#_ >= 1 && $_[1] eq "=") {
|
||||
$groups{$_[0]} = [] if !defined $groups{$_[0]};
|
||||
$listref = $groups{$_[0]};
|
||||
$prog = undef;
|
||||
shift @objs; # eat the group name
|
||||
} elsif ($_[1] eq ":") {
|
||||
} elsif ($#_ >= 1 && $_[1] eq ":") {
|
||||
$listref = [];
|
||||
$prog = $_[0];
|
||||
shift @objs; # eat the program name
|
||||
|
Loading…
Reference in New Issue
Block a user