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.226 by root, Mon Dec 12 12:56:04 2011 UTC vs.
Revision 1.227 by root, Tue Jan 10 13:32:23 2012 UTC

1476 if (@_ < 3) { 1476 if (@_ < 3) {
1477 # this is more than twice as fast as the generic code below 1477 # this is more than twice as fast as the generic code below
1478 sub { 1478 sub {
1479 $_[0]{rbuf} =~ s/^([^\015\012]*)(\015?\012)// or return; 1479 $_[0]{rbuf} =~ s/^([^\015\012]*)(\015?\012)// or return;
1480 1480
1481 $cb->($_[0], $1, $2); 1481 $cb->($_[0], "$1", "$2");
1482 1 1482 1
1483 } 1483 }
1484 } else { 1484 } else {
1485 $eol = quotemeta $eol unless ref $eol; 1485 $eol = quotemeta $eol unless ref $eol;
1486 $eol = qr|^(.*?)($eol)|s; 1486 $eol = qr|^(.*?)($eol)|s;
1487 1487
1488 sub { 1488 sub {
1489 $_[0]{rbuf} =~ s/$eol// or return; 1489 $_[0]{rbuf} =~ s/$eol// or return;
1490 1490
1491 $cb->($_[0], $1, $2); 1491 $cb->($_[0], "$1", "$2");
1492 1 1492 1
1493 } 1493 }
1494 } 1494 }
1495}; 1495};
1496 1496

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines