The inconsistent calling had already been noticed. Now the trap has been spotted, so clean this up.
Signed-off-by: Elliott Mitchell <ehem+open...@m5p.com> --- scripts/kconfig.pl | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/scripts/kconfig.pl b/scripts/kconfig.pl index 5a53e2154b..5f0741ee5c 100755 --- a/scripts/kconfig.pl +++ b/scripts/kconfig.pl @@ -125,9 +125,9 @@ sub dump_config($) { } } -sub parse_expr { - my $pos = shift; - my $mod_plus = shift; +sub parse_expr($$); +sub parse_expr($$) { + my ($pos, $mod_plus) = @_; my $arg = $arg[$$pos++]; my %ops = ( @@ -142,7 +142,7 @@ sub parse_expr { die "Parse error" if (!$arg); if (exists($ops{$arg})) { - my $arg1 = parse_expr($pos); + my $arg1 = parse_expr($pos, 0); my $arg2 = parse_expr($pos, ($arg eq 'm+') ? 1 : 0); return &{$ops{$arg}->[0]}($arg1, $arg2, $ops{$arg}->[1]); } else { @@ -163,5 +163,5 @@ while (@ARGV > 0 and $ARGV[0] =~ /^-\w+$/) { @arg = @ARGV; my $pos = 0; -dump_config(parse_expr(\$pos)); +dump_config(parse_expr(\$pos, 0)); die "Parse error" if ($arg[$pos]); -- (\___(\___(\______ --=> 8-) EHM <=-- ______/)___/)___/) \BS ( | ehem+open...@m5p.com PGP 87145445 | ) / \_CS\ | _____ -O #include <stddisclaimer.h> O- _____ | / _/ 8A19\___\_|_/58D2 7E3D DDF4 7BA6 <-PGP-> 41D1 B375 37D0 8714\_|_/___/5445 _______________________________________________ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel