use parent qw(Exporter);
use bytes;
use POSIX qw(WNOHANG sigprocmask SIG_SETMASK);
-use IO::Handle qw();
use Fcntl qw(SEEK_SET :DEFAULT O_APPEND);
use Time::HiRes qw(clock_gettime CLOCK_MONOTONIC);
use Scalar::Util qw(blessed);
sub set_cloexec ($) {
my ($fd) = @_;
- $_io = IO::Handle->new_from_fd($fd, 'r+') or return;
+ open($_io, '+<&=', $fd) or return;
defined(my $fl = fcntl($_io, F_GETFD, 0)) or return;
fcntl($_io, F_SETFD, $fl | FD_CLOEXEC);
}