From: Craig A. Berry Date: Sat, 2 Aug 2003 10:25:44 +0000 (-0500) Subject: on VMS, set non-blocking with ioctl, not fcntl X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=d135e0826fa12e553bd7097ce6e4ef5a65e18767;p=p5sagit%2Fp5-mst-13.2.git on VMS, set non-blocking with ioctl, not fcntl From: "Craig A. Berry" Message-ID: <3F2BD7F8.8090003@mac.com> p4raw-id: //depot/perl@20451 --- diff --git a/lib/Net/Ping.pm b/lib/Net/Ping.pm index 001ff2e..4f44106 100644 --- a/lib/Net/Ping.pm +++ b/lib/Net/Ping.pm @@ -316,9 +316,9 @@ sub socket_blocking_mode # set the non-blocking mode (set O_NONBLOCK) my $flags; - if ($^O eq 'MSWin32') { - # FIONBIO enables non-blocking sockets on windows. - # FIONBIO is (0x80000000|(4<<16)|(ord('f')<<8)|126), as per winsock.h. + if ($^O eq 'MSWin32' || $^O eq 'VMS') { + # FIONBIO enables non-blocking sockets on windows and vms. + # FIONBIO is (0x80000000|(4<<16)|(ord('f')<<8)|126), as per winsock.h, ioctl.h my $f = 0x8004667e; my $v = pack("L", $block ? 0 : 1); ioctl($fh, $f, $v) or croak("ioctl failed: $!");