diff options
-rw-r--r-- | lib/Tie/RefHash.pm | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/lib/Tie/RefHash.pm b/lib/Tie/RefHash.pm index 30a90d98af..2f0962819a 100644 --- a/lib/Tie/RefHash.pm +++ b/lib/Tie/RefHash.pm @@ -2,7 +2,7 @@ package Tie::RefHash; use vars qw/$VERSION/; -$VERSION = "1.34"; +$VERSION = "1.34_01"; =head1 NAME @@ -96,7 +96,12 @@ BEGIN { use Config (); my $usethreads = $Config::Config{usethreads}; # && exists $INC{"threads.pm"} *_HAS_THREADS = $usethreads ? sub () { 1 } : sub () { 0 }; - require Scalar::Util if $usethreads; # we need weaken() + if ($usethreads) { + # The magic of taint tunneling means that we can't do this require in the + # same statement as the boolean check on $usethreads, as $usethreads is + # tainted. + require Scalar::Util; + } } BEGIN { |