Subject: | Binding socket when using nondefault locale |
Date: | Fri, 15 May 2009 14:45:35 +0400 |
To: | bug-Net-SSH-Perl [...] rt.cpan.org |
From: | Vieryn <vieryn [...] gmail.com> |
Hi
When using nonenglish locale error message "Address already in use" can be translated to other language and line
if ($! =~ /Address already in use/i)
of sub _create_socket in Perl.pm working not prorerly
for example:
#! /usr/bin/perl -w
use Net::SSH::Perl;
$SSH_SERVER_ADDRESS=Your_ssh_server_address; #replace it with your ssh server address
my $ssh1=Net::SSH::Perl->new($SSH_SERVER_ADDRESS);
my $ssh2=Net::SSH::Perl->new($SSH_SERVER_ADDRESS);
Execute it with
LC_ALL=ru_RU.UTF-8 ./sshbug.pl
or with any other nonenglish locale, and it crush on second new
When using nonenglish locale error message "Address already in use" can be translated to other language and line
if ($! =~ /Address already in use/i)
of sub _create_socket in Perl.pm working not prorerly
for example:
#! /usr/bin/perl -w
use Net::SSH::Perl;
$SSH_SERVER_ADDRESS=Your_ssh_server_address; #replace it with your ssh server address
my $ssh1=Net::SSH::Perl->new($SSH_SERVER_ADDRESS);
my $ssh2=Net::SSH::Perl->new($SSH_SERVER_ADDRESS);
Execute it with
LC_ALL=ru_RU.UTF-8 ./sshbug.pl
or with any other nonenglish locale, and it crush on second new