--- AnyEvent/eg/handle 2008/05/15 07:51:25 1.1 +++ AnyEvent/eg/handle 2008/05/24 23:34:28 1.3 @@ -1,4 +1,5 @@ #!/opt/bin/perl + # This small example script shows how to do non-blocking # reads from a file handle. @@ -11,9 +12,8 @@ on_eof => sub { $cv->broadcast } ); -$ae_fh->push_read_line (sub { +$ae_fh->push_read (line => sub { my ($ae_fh, $line) = @_; - chomp $line; print "Got line [$line]\n"; $ae_fh->push_read (sub {