From: Steinar H. Gunderson Date: Sun, 16 Nov 2014 10:35:11 +0000 (+0100) Subject: Fix PGN parsing; it was broken by a scoping change. X-Git-Url: https://git.sesse.net/?p=remoteglot;a=commitdiff_plain;h=96875773d3cd75a57b13cba9d1497c616cf76503;ds=sidebyside Fix PGN parsing; it was broken by a scoping change. --- diff --git a/remoteglot.pl b/remoteglot.pl index 4e6edc6..b128e29 100755 --- a/remoteglot.pl +++ b/remoteglot.pl @@ -266,7 +266,8 @@ sub handle_pgn { my $moves = $pgn->moves; my @uci_moves = (); for my $move (@$moves) { - my ($pos, $uci_move) = $pos->make_pretty_move($move); + my $uci_move; + ($pos, $uci_move) = $pos->make_pretty_move($move); push @uci_moves, $uci_move; } $pos->{'history'} = \@uci_moves; @@ -930,7 +931,8 @@ sub handle_tb_lookup_return { my $moves = $pgn->moves; my @uci_moves = (); for my $move (@$moves) { - my ($pvpos, $uci_move) = $pvpos->make_pretty_move($move); + my $uci_move; + ($pvpos, $uci_move) = $pvpos->make_pretty_move($move); push @uci_moves, $uci_move; } $tb_cache{$fen} = {