Skip to content

Commit

Permalink
THRIFT-590: send/recv timeout values interchanged in perl socket lib
Browse files Browse the repository at this point in the history
git-svn-id: https://svn.apache.org/repos/asf/incubator/thrift/trunk@835200 13f79535-47bb-0310-9956-ffa450edef68
  • Loading branch information
tjake committed Nov 12, 2009
1 parent e2e4ea1 commit 93f8219
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/perl/lib/Thrift/Socket.pm
Expand Up @@ -196,7 +196,7 @@ sub read
return unless defined $self->{handle};

#check for timeout
my @sockets = $self->{handle}->can_read( $self->{sendTimeout} / 1000 );
my @sockets = $self->{handle}->can_read( $self->{recvTimeout} / 1000 );

if(@sockets == 0){
die new Thrift::TException('TSocket: timed out reading '.$len.' bytes from '.
Expand Down Expand Up @@ -236,7 +236,7 @@ sub write


#check for timeout
my @sockets = $self->{handle}->can_write( $self->{recvTimeout} / 1000 );
my @sockets = $self->{handle}->can_write( $self->{sendTimeout} / 1000 );

if(@sockets == 0){
die new Thrift::TException('TSocket: timed out writing to bytes from '.
Expand Down

0 comments on commit 93f8219

Please sign in to comment.