ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/AnyEvent/lib/AnyEvent/Handle.pm
(Generate patch)

Comparing AnyEvent/lib/AnyEvent/Handle.pm (file contents):
Revision 1.223 by root, Thu Sep 1 04:07:18 2011 UTC vs.
Revision 1.224 by root, Mon Sep 5 07:21:54 2011 UTC

1081=cut 1081=cut
1082 1082
1083register_write_type storable => sub { 1083register_write_type storable => sub {
1084 my ($self, $ref) = @_; 1084 my ($self, $ref) = @_;
1085 1085
1086 require Storable; 1086 require Storable unless $Storable::VERSION;
1087 1087
1088 pack "w/a*", Storable::nfreeze ($ref) 1088 pack "w/a*", Storable::nfreeze ($ref)
1089}; 1089};
1090 1090
1091=back 1091=back
1711=cut 1711=cut
1712 1712
1713register_read_type storable => sub { 1713register_read_type storable => sub {
1714 my ($self, $cb) = @_; 1714 my ($self, $cb) = @_;
1715 1715
1716 require Storable; 1716 require Storable unless $Storable::VERSION;
1717 1717
1718 sub { 1718 sub {
1719 # when we can use 5.10 we can use ".", but for 5.8 we use the re-pack method 1719 # when we can use 5.10 we can use ".", but for 5.8 we use the re-pack method
1720 defined (my $len = eval { unpack "w", $_[0]{rbuf} }) 1720 defined (my $len = eval { unpack "w", $_[0]{rbuf} })
1721 or return; 1721 or return;

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines