Skip Menu |

Preferred bug tracker

Please visit the preferred bug tracker to report your issue.

This queue is for tickets about the Redis CPAN distribution.

Report information
The Basics
Id: 62489
Status: resolved
Priority: 0/
Queue: Redis

People
Owner: melo [...] cpan.org
Requestors: mjy [...] geizhals.at
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Subject: ping() dies on disconnect (1.2001)
Date: Wed, 27 Oct 2010 17:03:50 +0200
To: bug-Redis [...] rt.cpan.org
From: Marinos Yannikos <mjy [...] geizhals.at>
The ping() method should/could be used to detect server disconnects, but it dies instead of returning false, so it is not very useful: can't read socket: at /usr/local/share/perl/5.10.0/Redis.pm line 120. Regards, Marinos -- Dipl.-Ing. Marinos Yannikos, CEO Preisvergleich Internet Services AG Obere Donaustrasse 63, A-1020 Wien Tel./Fax: (+431) 5811609-52/-55 Handelsgericht Wien - FN 197241K - Firmensitz Wien
Subject: [rt.cpan.org #62489] Fix for ping
Date: Tue, 4 Jan 2011 16:40:41 -0500
To: bug-redis [...] rt.cpan.org
From: Brian Dunavant <brian [...] omniti.com>
Along with my change in #64472 the following code should cause ping to work like it says it should in the POD documentation and fixes this bug. In AUTOLOAD change the following line from: my $result = <$sock> || die "can't read socket: $!"; to: my $result; eval { $result = <$sock> || $self->__reconnect_and_retry($send) || die "can't read socket: $!"; }; if( $@ ) { return undef if $command eq 'ping'; die $@; }
Hi, fixed in https://github.com/melo/perl- redis/commit/b40b59522c0266b3f81b407b3ddab4ece7fd7036 Expect a 1.902 release before the end of the day.
Fixed with the release of 1.902. Thanks, -- Hi, how are you?