Subject: | filter_read in block mode makes DATA handle empty |
Found while debugging bug report for Switch: https://rt.cpan.org/Ticket/Display.html?id=97440
Test case attached.
If I remove "use S1;" there is content in DATA.
--
Alexandr Ciornii, http://chorny.net
Subject: | S1.pm |
package S1;
use strict;
use Filter::Util::Call;
sub import
{
filter_add({});
1;
}
sub unimport
{
filter_del()
}
sub filter
{
my($self) = @_ ;
my $status = 1;
$status = filter_read(1_000_000);
print "code: !$_!\n\n";
return $status;
}
1;
Subject: | t.pl |
#!/usr/bin/perl -w
use S1;
print 'data: ', <DATA>;
__DATA__
test