Commit 357b5309 authored by Birte Kristina Friesel's avatar Birte Kristina Friesel
Browse files

Decode all arguments (thanks mxey)

parent d1ead7ba
Loading
Loading
Loading
Loading
+2 −5
Original line number Diff line number Diff line
@@ -136,6 +136,8 @@ sub display_connection {
	return;
}

@ARGV = map { decode( 'UTF-8', $_ ) } @ARGV;

#<<<
GetOptions(
	$opt,
@@ -178,11 +180,6 @@ for my $pair ( [ \@from, \$from_type ], [ \@via, \$via_type ],
	[ \@to, \$to_type ], )
{

	if ( @{ $pair->[0] } ) {
		$pair->[0]->[0] = decode( 'UTF-8', $pair->[0]->[0] );
		$pair->[0]->[1] = decode( 'UTF-8', $pair->[0]->[1] );
	}

	next if ( not defined $pair->[0]->[1] );

	if (