lib/File/Find.pm for QNX, NTO
[p5sagit/p5-mst-13.2.git] / lib / diagnostics.pm
index b224943..c68fa3f 100755 (executable)
@@ -168,10 +168,10 @@ Tom Christiansen <F<tchrist@mox.perl.com>>, 25 June 1995.
 =cut
 
 use strict;
-use 5.6.0;
+use 5.006;
 use Carp;
 
-our $VERSION = 1.0;
+our $VERSION = 1.1;
 our $DEBUG;
 our $VERBOSE;
 our $PRETTY;
@@ -411,7 +411,7 @@ sub import {
     shift;
     $^W = 1; # yup, clobbered the global variable; 
             # tough, if you want diags, you want diags.
-    return if $SIG{__WARN__} eq \&warn_trap;
+    return if defined $SIG{__WARN__} && ($SIG{__WARN__} eq \&warn_trap);
 
     for (@_) {