> > And the check_addr.pl program simply looks like this
> > #!/usr/bin/perl
> > my $email = <>;
> > chomp($email);
> > print 1;
> >
> > It doesn't seem to ever be able to read the data that check_addr
> > sends back.  Should I be doing this another way?
>
> POE::Wheel::Run expects to receive lines of data.  You may need to add
> a newline to your print() statement.

.... and you should probably unbuffer STDOUT as well.

Put this line

$| = 1;

before the rest of the code, and include a newline in your output:

> > #!/usr/bin/perl
$| = 1;
> > my $email = <>;
> > chomp($email);
print "1\n";

In fact, now that I think about it, the missing newline in your output is
VERY probably the reason POE never saw anything... remember the "Filter"
parameter, above?  That's what POE uses to know when a complete block of
input/output has happened with the child process.

HTH!

L8r,
Rob

Reply via email to