Skip Menu |

This queue is for tickets about the IO-Ppoll CPAN distribution.

Report information
The Basics
Id: 107033
Status: new
Priority: 0/
Queue: IO-Ppoll

People
Owner: Nobody in particular
Requestors: leonerd-cpan [...] leonerd.org.uk
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Subject: ->mask_add can't initialise a new filehandle
See attached. -- Paul Evans
Subject: io-ppoll.txt
#!/usr/bin/perl # mask_add bug use IO::Ppoll qw( POLLOUT ); use IO::Socket; use strict; use warnings; my $s = IO::Socket::INET->new(Proto => 'udp', LocalPort => 6665, PeerAddr => 'localhost:6667', Reuse => 1) or die $@; my $poll = IO::Ppoll->new; # ERROR HERE - uncomment one or the other - both should do the same $poll->mask_add($s => POLLOUT); # this one FAILS #$poll->mask($s => $poll->mask($s) | POLLOUT ); # this one WORKS $poll->poll; for my $fh ( $poll->handles(POLLOUT) ) { defined $fh or die "undefined file handle returned, should never happen"; } print "OK\n";