Hello community,

here is the log from the commit of package perl-Test-Taint for openSUSE:Factory 
checked in at 2013-06-06 13:56:31
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/perl-Test-Taint (Old)
 and      /work/SRC/openSUSE:Factory/.perl-Test-Taint.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "perl-Test-Taint"

Changes:
--------
--- /work/SRC/openSUSE:Factory/perl-Test-Taint/perl-Test-Taint.changes  
2011-09-23 12:39:10.000000000 +0200
+++ /work/SRC/openSUSE:Factory/.perl-Test-Taint.new/perl-Test-Taint.changes     
2013-06-06 13:56:32.000000000 +0200
@@ -1,0 +2,15 @@
+Tue Jun  4 15:09:35 UTC 2013 - [email protected]
+
+- updated to 1.06
+       [ENHANCEMENTS]
+       tainted() now localizes $SIG{__DIE__} before performing the
+       taint check.  If the calling program has its own $SIG{__DIE__},
+       we don't want to use it.  Thanks, Pete Krawczyk.
+       https://rt.cpan.org/Ticket/Display.html?id=23507
+
+       [FIXES]
+       Checks for undef before opening files when trying to create
+       some taint. Thanks Frédéric Buclin.
+       https://rt.cpan.org/Ticket/Display.html?id=51246
+
+-------------------------------------------------------------------

Old:
----
  Test-Taint-1.04.tar.gz

New:
----
  Test-Taint-1.06.tar.gz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ perl-Test-Taint.spec ++++++
--- /var/tmp/diff_new_pack.pOvqLC/_old  2013-06-06 13:56:32.000000000 +0200
+++ /var/tmp/diff_new_pack.pOvqLC/_new  2013-06-06 13:56:32.000000000 +0200
@@ -1,7 +1,7 @@
 #
 # spec file for package perl-Test-Taint
 #
-# Copyright (c) 2011 SUSE LINUX Products GmbH, Nuernberg, Germany.
+# Copyright (c) 2013 SUSE LINUX Products GmbH, Nuernberg, Germany.
 #
 # All modifications and additions to the file contributed by third parties
 # remain the property of their copyright owners, unless otherwise agreed
@@ -16,19 +16,23 @@
 #
 
 
-
 Name:           perl-Test-Taint
-Version:        1.04
-Release:        1
-License:        GPL-1.0+ or Artistic-1.0
+Version:        1.06
+Release:        0
 %define cpan_name Test-Taint
 Summary:        Tools to test taintedness
-Url:            http://search.cpan.org/dist/Test-Taint/
+License:        GPL-1.0+ or Artistic-1.0
 Group:          Development/Libraries/Perl
+Url:            http://search.cpan.org/dist/Test-Taint/
 Source:         
http://www.cpan.org/authors/id/P/PE/PETDANCE/%{cpan_name}-%{version}.tar.gz
 BuildRoot:      %{_tmppath}/%{name}-%{version}-build
 BuildRequires:  perl
 BuildRequires:  perl-macros
+#BuildRequires: perl(My::ObjectHash)
+#BuildRequires: perl(Test::Taint)
+#BuildRequires: perl(Tie::StdArray)
+#BuildRequires: perl(Tie::StdHash)
+#BuildRequires: perl(Tie::StdScalar)
 %{perl_requires}
 
 %description
@@ -57,9 +61,6 @@
 %perl_process_packlist
 %perl_gen_filelist
 
-%clean
-%{__rm} -rf %{buildroot}
-
 %files -f %{name}.files
 %defattr(-,root,root,755)
 %doc Changes

++++++ Test-Taint-1.04.tar.gz -> Test-Taint-1.06.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Test-Taint-1.04/Changes new/Test-Taint-1.06/Changes
--- old/Test-Taint-1.04/Changes 2004-08-10 05:06:27.000000000 +0200
+++ new/Test-Taint-1.06/Changes 2012-10-19 18:30:43.000000000 +0200
@@ -1,5 +1,18 @@
 Revision history for Perl extension Test::Taint
 
+1.06    Fri Oct 19 11:30:31 CDT 2012
+        [ENHANCEMENTS]
+        tainted() now localizes $SIG{__DIE__} before performing the
+        taint check.  If the calling program has its own $SIG{__DIE__},
+        we don't want to use it.  Thanks, Pete Krawczyk.
+        https://rt.cpan.org/Ticket/Display.html?id=23507
+
+        [FIXES]
+        Checks for undef before opening files when trying to create
+        some taint. Thanks Frédéric Buclin.
+        https://rt.cpan.org/Ticket/Display.html?id=51246
+
+
 1.04    Mon Aug  9 22:06:10 CDT 2004
         No differences from 1.03_01.
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Test-Taint-1.04/MANIFEST new/Test-Taint-1.06/MANIFEST
--- old/Test-Taint-1.04/MANIFEST        2004-07-01 06:47:12.000000000 +0200
+++ new/Test-Taint-1.06/MANIFEST        2012-10-19 18:31:16.000000000 +0200
@@ -1,7 +1,6 @@
 Changes
 Makefile.PL
 MANIFEST
-META.yml
 ppport.h
 t/00.load.t
 t/no-dash-T.t
@@ -14,3 +13,5 @@
 t/tainted_ok_deeply.t
 Taint.pm
 Taint.xs
+META.yml                                 Module YAML meta-data (added by 
MakeMaker)
+META.json                                Module JSON meta-data (added by 
MakeMaker)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Test-Taint-1.04/META.json 
new/Test-Taint-1.06/META.json
--- old/Test-Taint-1.04/META.json       1970-01-01 01:00:00.000000000 +0100
+++ new/Test-Taint-1.06/META.json       2012-10-19 18:31:16.000000000 +0200
@@ -0,0 +1,47 @@
+{
+   "abstract" : "Checks for taintedness of variables",
+   "author" : [
+      "unknown"
+   ],
+   "dynamic_config" : 1,
+   "generated_by" : "ExtUtils::MakeMaker version 6.62, CPAN::Meta::Converter 
version 2.112621",
+   "license" : [
+      "unknown"
+   ],
+   "meta-spec" : {
+      "url" : "http://search.cpan.org/perldoc?CPAN::Meta::Spec";,
+      "version" : "2"
+   },
+   "name" : "Test-Taint",
+   "no_index" : {
+      "directory" : [
+         "t",
+         "inc"
+      ]
+   },
+   "prereqs" : {
+      "build" : {
+         "requires" : {
+            "ExtUtils::MakeMaker" : 0
+         }
+      },
+      "configure" : {
+         "requires" : {
+            "ExtUtils::MakeMaker" : 0
+         }
+      },
+      "runtime" : {
+         "requires" : {
+            "Scalar::Util" : 0,
+            "Test::Builder" : 0,
+            "Test::More" : 0,
+            "Tie::Array" : 0,
+            "Tie::Hash" : 0,
+            "Tie::Scalar" : 0,
+            "overload" : 0
+         }
+      }
+   },
+   "release_status" : "stable",
+   "version" : "1.06"
+}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Test-Taint-1.04/META.yml new/Test-Taint-1.06/META.yml
--- old/Test-Taint-1.04/META.yml        2004-08-10 05:06:35.000000000 +0200
+++ new/Test-Taint-1.06/META.yml        2012-10-19 18:31:16.000000000 +0200
@@ -1,17 +1,28 @@
-# http://module-build.sourceforge.net/META-spec.html
-#XXXXXXX This is a prototype!!!  It will change in the future!!! XXXXX#
-name:         Test-Taint
-version:      1.04
-version_from: Taint.pm
-installdirs:  site
+---
+abstract: 'Checks for taintedness of variables'
+author:
+  - unknown
+build_requires:
+  ExtUtils::MakeMaker: 0
+configure_requires:
+  ExtUtils::MakeMaker: 0
+dynamic_config: 1
+generated_by: 'ExtUtils::MakeMaker version 6.62, CPAN::Meta::Converter version 
2.112621'
+license: unknown
+meta-spec:
+  url: http://module-build.sourceforge.net/META-spec-v1.4.html
+  version: 1.4
+name: Test-Taint
+no_index:
+  directory:
+    - t
+    - inc
 requires:
-    overload:                      0
-    Scalar::Util:                  0
-    Test::Builder:                 0
-    Test::More:                    0
-    Tie::Array:                    0
-    Tie::Hash:                     0
-    Tie::Scalar:                   0
-
-distribution_type: module
-generated_by: ExtUtils::MakeMaker version 6.21
+  Scalar::Util: 0
+  Test::Builder: 0
+  Test::More: 0
+  Tie::Array: 0
+  Tie::Hash: 0
+  Tie::Scalar: 0
+  overload: 0
+version: 1.06
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Test-Taint-1.04/Makefile.PL 
new/Test-Taint-1.06/Makefile.PL
--- old/Test-Taint-1.04/Makefile.PL     2004-07-01 06:16:59.000000000 +0200
+++ new/Test-Taint-1.06/Makefile.PL     2012-10-19 17:46:47.000000000 +0200
@@ -19,3 +19,12 @@
     dist                => { COMPRESS => 'gzip -9f', SUFFIX => 'gz', },
     clean               => { FILES => 'Test-Taint-*' },
 );
+
+sub MY::postamble {
+    return <<'MAKE';
+.PHONY: critic
+
+critic:
+       perlcritic -1 -q -profile perlcriticrc Taint.pm t/*.t
+MAKE
+}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Test-Taint-1.04/Taint.pm new/Test-Taint-1.06/Taint.pm
--- old/Test-Taint-1.04/Taint.pm        2004-08-10 05:06:57.000000000 +0200
+++ new/Test-Taint-1.06/Taint.pm        2012-10-19 18:26:21.000000000 +0200
@@ -1,19 +1,20 @@
 package Test::Taint;
 
+## no critic (Bangs::ProhibitVagueNames)
+## We're dealing with abstract vars like "$var" in this code.
+
 =head1 NAME
 
 Test::Taint - Tools to test taintedness
 
 =head1 VERSION
 
-Version 1.04
-
-    $Header: /home/cvs/test-taint/Taint.pm,v 1.16 2004/08/10 03:06:57 andy Exp 
$
+Version 1.06
 
 =cut
 
 use vars qw( $VERSION );
-$VERSION = "1.04";
+$VERSION = "1.06";
 
 =head1 SYNOPSIS
 
@@ -51,7 +52,7 @@
 my $Test = Test::Builder->new;
 
 use vars qw( @EXPORT );
-@EXPORT = qw( 
+@EXPORT = qw(
     taint             taint_deeply
     tainted           tainted_deeply
     tainted_ok        tainted_ok_deeply
@@ -67,7 +68,7 @@
     my $caller = caller;
     no strict 'refs';
     for my $sub ( @EXPORT ) {
-        *{$caller.'::'.$sub} = \&$sub;
+        *{$caller.'::'.$sub} = \&{$sub};
     }
     $Test->exported_to($caller);
     $Test->plan(@_);
@@ -89,10 +90,10 @@
             or next;
 
         # taint the contents of tied objects
-        if(my $tied = $realtype eq 'HASH'   ? tied %$node : 
-                      $realtype eq 'ARRAY'  ? tied @$node :
-                      $realtype eq 'SCALAR' ? tied $$node : 
-                      $realtype eq 'REF'    ? tied $$node : undef)  {
+        if(my $tied = $realtype eq 'HASH'   ? tied %{$node} :
+                      $realtype eq 'ARRAY'  ? tied @{$node} :
+                      $realtype eq 'SCALAR' ? tied ${$node} :
+                      $realtype eq 'REF'    ? tied ${$node} : undef) {
             push @stack, $tied;
             next;
         }
@@ -103,10 +104,10 @@
 
         # perform an action on the node, then push them on the stack for 
traversal
         push @stack,
-            $realtype eq 'HASH'   ? $callback->(values %$node) :
-            $realtype eq 'ARRAY'  ? $callback->(@$node)        :
-            $realtype eq 'SCALAR' ? $callback->($$node)        :
-            $realtype eq 'REF'    ? $callback->($$node)        :
+            $realtype eq 'HASH'   ? $callback->(values %{$node}) :
+            $realtype eq 'ARRAY'  ? $callback->(@{$node})        :
+            $realtype eq 'SCALAR' ? $callback->(${$node})        :
+            $realtype eq 'REF'    ? $callback->(${$node})        :
             map $callback->(*$node{$_}), qw(SCALAR ARRAY HASH);   #must be a 
GLOB
     }
 
@@ -205,7 +206,7 @@
 sub untainted_ok_deeply {
     my $var = shift;
     my $msg = shift;
-   
+
     my $ok = !tainted_deeply( $var );
     $Test->ok( $ok, $msg );
 
@@ -237,7 +238,7 @@
 sub tainted {
     no warnings qw(void uninitialized);
 
-    return !eval { join('', shift), kill 0; 1 };
+    return !eval { local $SIG{__DIE__} = 'DEFAULT'; join('', shift), kill 0; 1 
};
 } # tainted
 
 =head2 tainted_deeply( I<$var> )
@@ -310,6 +311,8 @@
         sub { taint @_; @_ },
         @_,
     );
+
+    return;
 } # taint_deeply
 
 BEGIN {
@@ -323,7 +326,7 @@
         last if tainted $TAINT;
 
         # Let's try again. Maybe somebody cleaned those.
-        $TAINT = substr(join("", @ARGV, %ENV), 0, 0);
+        $TAINT = substr(join('', @ARGV, %ENV), 0, 0);
         last if tainted $TAINT;
 
         # If those don't work, go try to open some file from some unsafe
@@ -331,10 +334,11 @@
         # (Yes, even reading from /dev/null works!)
         local(*FOO);
         for ( qw(/dev/null / . ..), values %INC, $0, $^X ) {
+            next unless defined $_;
             if ( open FOO, $_ ) {
-                my $data;
-                if ( defined sysread FOO, $data, 1 ) {
-                    $TAINT = substr( $data, 0, 0 );
+                my $potentially_tainted_data;
+                if ( defined sysread FOO, $potentially_tainted_data, 1 ) {
+                    $TAINT = substr( $potentially_tainted_data, 0, 0 );
                     last if tainted $TAINT;
                 }
             }
@@ -343,7 +347,7 @@
     }
 
     # Sanity check
-    die "Our taintbrush should have zero length!" if length $TAINT;
+    die 'Our taintbrush should have zero length!' if length $TAINT;
 }
 
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Test-Taint-1.04/t/00.load.t 
new/Test-Taint-1.06/t/00.load.t
--- old/Test-Taint-1.04/t/00.load.t     2004-02-04 06:47:22.000000000 +0100
+++ new/Test-Taint-1.06/t/00.load.t     2012-10-19 17:46:47.000000000 +0200
@@ -1,7 +1,12 @@
-# $Id: 00.load.t,v 1.1.1.1 2004/02/04 03:46:16 andy Exp $
+#!perl -T
+
+use strict;
+use warnings;
 
 use Test::More tests => 1;
 
-use_ok( 'Test::Taint' );
+use Test::Taint;
+
+diag( "Testing Test::Taint $Test::Taint::VERSION, Perl $], $^X" );
 
-diag( "Testing Test::Taint $Test::Taint::VERSION" );
+pass( 'Module loaded OK' );
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Test-Taint-1.04/t/no-dash-T.t 
new/Test-Taint-1.06/t/no-dash-T.t
--- old/Test-Taint-1.04/t/no-dash-T.t   2004-03-15 02:05:32.000000000 +0100
+++ new/Test-Taint-1.06/t/no-dash-T.t   2012-10-19 18:22:06.000000000 +0200
@@ -1,11 +1,13 @@
 #!perl -w
+# Note the lack of -T in the shebang
 
-# Note the lack of -T there
+use warnings;
+use strict;
 
 use Test::Taint tests=>4;
 use Test::More;
 
-ok( !taint_checking(), "Taint checking is off" );
+ok( !taint_checking(), 'Taint checking is off' );
 
 my $foo = 43;
 untainted_ok( $foo, 'Starts clean' );
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Test-Taint-1.04/t/pod-coverage.t 
new/Test-Taint-1.06/t/pod-coverage.t
--- old/Test-Taint-1.04/t/pod-coverage.t        2004-02-14 06:20:39.000000000 
+0100
+++ new/Test-Taint-1.06/t/pod-coverage.t        2012-10-19 18:10:16.000000000 
+0200
@@ -1,4 +1,15 @@
+#!perl -T
+
+use strict;
+use warnings;
+
 use Test::More;
-eval "use Test::Pod::Coverage 0.08";
-plan skip_all => "Test::Pod::Coverage 0.08 required for testing POD coverage" 
if $@;
-all_pod_coverage_ok();
+
+my $module = 'Test::Pod::Coverage 1.04';
+
+if ( eval "use $module; 1;" ) { ## no critic (ProhibitStringyEval)
+    all_pod_coverage_ok();
+}
+else {
+    plan skip_all => "$module required for testing POD";
+}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Test-Taint-1.04/t/pod.t new/Test-Taint-1.06/t/pod.t
--- old/Test-Taint-1.04/t/pod.t 2004-02-04 04:46:16.000000000 +0100
+++ new/Test-Taint-1.06/t/pod.t 2012-10-19 18:08:14.000000000 +0200
@@ -1,4 +1,13 @@
+#!perl -Tw
+
+use warnings;
+use strict;
+
 use Test::More;
-eval "use Test::Pod 1.00";
-plan skip_all => "Test::Pod 1.00 required for testing POD" if $@;
-all_pod_files_ok();
+
+if ( eval 'use Test::Pod 1.14; 1;' ) { ## no critic (ProhibitStringyEval)
+    all_pod_files_ok();
+}
+else {
+    plan skip_all => 'Test::Pod 1.14 required for testing POD';
+}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Test-Taint-1.04/t/taint.t 
new/Test-Taint-1.06/t/taint.t
--- old/Test-Taint-1.04/t/taint.t       2004-07-01 06:09:23.000000000 +0200
+++ new/Test-Taint-1.06/t/taint.t       2012-10-19 18:28:27.000000000 +0200
@@ -1,7 +1,10 @@
 #!perl -T
 
+use warnings;
+use strict;
+
 BEGIN {
-    for($0, $^X) {
+    for($0, $^X) { ## no critic (Variables::ProhibitPunctuationVars)
         ($_) = /(.*)/;
     }
 }
@@ -9,7 +12,7 @@
 use Test::More;
 use Test::Taint tests => 10;
 
-use constant VAR => 'VAR';
+use constant VAR => 'VAR'; ## no critic 
(ValuesAndExpressions::ProhibitConstantPragma)
 
 taint_checking_ok();
 
@@ -17,7 +20,7 @@
 untainted_ok( $foo, 'Starts clean' );
 taint($foo);
 tainted_ok( $foo, 'Gets dirty' );
-$foo =~ /(\d+)/;
+$foo =~ /(\d+)/ or die;
 $foo = $1;
 untainted_ok( $foo, 'Reclean' );
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Test-Taint-1.04/t/taint_deeply.t 
new/Test-Taint-1.06/t/taint_deeply.t
--- old/Test-Taint-1.04/t/taint_deeply.t        2004-07-01 06:09:23.000000000 
+0200
+++ new/Test-Taint-1.06/t/taint_deeply.t        2012-10-19 18:27:33.000000000 
+0200
@@ -1,5 +1,9 @@
 #!perl -T
 
+## Two techniques that are bad in general but necessary in this test.
+## no critic (Miscellanea::ProhibitTies)
+## no critic (Modules::ProhibitMultiplePackages)
+
 use strict;
 use warnings FATAL => 'all';
 use Test::More;
@@ -13,14 +17,14 @@
         unknown => undef,
     );
 
-    $hash{circular} = \%hash; 
+    $hash{circular} = \%hash;
 
     untainted_ok( $hash{value}, 'Starts clean' );
     taint_deeply( \%hash );
     tainted_ok( $hash{value}, 'Gets dirty' );
     is( $hash{value}, 7, 'value stays the same' );
 
-    $hash{value} =~ /\A(\d+)\z/;
+    $hash{value} =~ /\A(\d+)\z/ or die;
     $hash{value} = $1;
 
     untainted_ok( $hash{value}, 'Reclean' );
@@ -37,7 +41,7 @@
     tainted_ok( $array[0], 'Gets dirty' );
     is( $array[0], 7, 'value stays the same' );
 
-    $array[0] =~ /\A(\d+)\z/;
+    $array[0] =~ /\A(\d+)\z/ or die;
     $array[0] = $1;
 
     untainted_ok( $array[0], 'Reclean' );
@@ -52,7 +56,7 @@
     tainted_ok( $scalar, 'Gets dirty' );
     is( $scalar, 14, 'value stays the same' );
 
-    $scalar =~ /\A(\d+)\z/;
+    $scalar =~ /\A(\d+)\z/ or die;
     $scalar = $1;
 
     untainted_ok( $scalar, 'Reclean' );
@@ -83,20 +87,20 @@
     is( $x[2],  70, 'value stays the same' );
     is( $x[3],  77, 'value stays the same' );
 
-    $x =~ /\A(\d+)\z/;
+    $x =~ /\A(\d+)\z/ or die;
     $x = $1;
 
     untainted_ok( $x, 'Reclean' );
 
     foreach my $value (values %x) {
-        $value =~ /\A(\d+)\z/;
+        $value =~ /\A(\d+)\z/ or die;
         $value = $1;
     }
 
     untainted_ok( $x{$_}, 'Reclean' ) foreach keys %x;
 
     foreach my $element (@x) {
-        $element =~ /\A(\d+)\z/;
+        $element =~ /\A(\d+)\z/ or die;
         $element = $1;
     }
 
@@ -116,7 +120,7 @@
 TAINT_A_HASH_OBJECT: {
     {
         package My::ObjectHash;
-        sub new { bless {} => shift };
+        sub new { return bless {} => shift };
     }
 
     my $hash_object = My::ObjectHash->new;
@@ -128,7 +132,7 @@
     tainted_ok( $hash_object->{value}, 'Gets dirty' );
     is( $hash_object->{value}, 84, 'value stays the same' );
 
-    $hash_object->{value} =~ /\A(\d+)\z/;
+    $hash_object->{value} =~ /\A(\d+)\z/ or die;
     $hash_object->{value} = $1;
 
     untainted_ok( $hash_object->{value}, 'Reclean' );
@@ -139,7 +143,7 @@
 TAINT_AN_ARRAY_OBJECT: {
     {
         package My::ObjectArray;
-        sub new { bless [] => shift };
+        sub new { return bless [] => shift };
     }
 
     my $array_object = My::ObjectArray->new;
@@ -151,7 +155,7 @@
     tainted_ok( $array_object->[0], 'Gets dirty' );
     is( $array_object->[0], 84, 'value stays the same' );
 
-    $array_object->[0] =~ /\A(\d+)\z/;
+    $array_object->[0] =~ /\A(\d+)\z/ or die;
     $array_object->[0] = $1;
 
     untainted_ok( $array_object->[0], 'Reclean' );
@@ -162,49 +166,49 @@
 TAINT_A_SCALAR_OBJECT: {
     {
         package My::ObjectScalar;
-        sub new { my $scalar; bless \$scalar => shift };
+        sub new { my $scalar; return bless \$scalar => shift };
     }
 
     my $scalar_object = My::ObjectScalar->new;
     isa_ok( $scalar_object, 'My::ObjectScalar' );
-    $$scalar_object = 84;
+    ${$scalar_object} = 84;
 
-    untainted_ok( $$scalar_object, 'Starts clean' );
+    untainted_ok( ${$scalar_object}, 'Starts clean' );
     taint_deeply( $scalar_object );
-    tainted_ok( $$scalar_object, 'Gets dirty' );
-    is( $$scalar_object, 84, 'value stays the same' );
+    tainted_ok( ${$scalar_object}, 'Gets dirty' );
+    is( ${$scalar_object}, 84, 'value stays the same' );
 
-    $$scalar_object =~ /\A(\d+)\z/;
-    $$scalar_object = $1;
+    ${$scalar_object} =~ /\A(\d+)\z/ or die;
+    ${$scalar_object} = $1;
 
-    untainted_ok( $$scalar_object, 'Reclean' );
-    is( $$scalar_object, 84, 'value stays the same' );
+    untainted_ok( ${$scalar_object}, 'Reclean' );
+    is( ${$scalar_object}, 84, 'value stays the same' );
     isa_ok( $scalar_object, 'My::ObjectScalar' );
 }
 
 TAINT_A_REF: {
     {
         package My::ObjectRef;
-        sub new { 
+        sub new {
             my $ref = \my %hash;;
-            bless \$ref, => shift;
+            return bless \$ref, => shift;
          };
     }
 
     my $ref_object = My::ObjectRef->new;
     isa_ok( $ref_object, 'My::ObjectRef' );
-    $$ref_object->{key} = 1;
+    ${$ref_object}->{key} = 1;
 
-    untainted_ok( $$ref_object->{key}, 'Starts clean' );
+    untainted_ok( ${$ref_object}->{key}, 'Starts clean' );
     taint_deeply( $ref_object );
-    tainted_ok( $$ref_object->{key}, 'Gets dirty' );
-    is( $$ref_object->{key}, 1, 'value stays the same' );
+    tainted_ok( ${$ref_object}->{key}, 'Gets dirty' );
+    is( ${$ref_object}->{key}, 1, 'value stays the same' );
 
-    $$ref_object->{key} =~ /\A(\d+)\z/;
-    $$ref_object->{key} = $1;
+    ${$ref_object}->{key} =~ /\A(\d+)\z/ or die;
+    ${$ref_object}->{key} = $1;
 
-    untainted_ok( $$ref_object->{key}, 'Reclean' );
-    is( $$ref_object->{key}, 1, 'value stays the same' );
+    untainted_ok( ${$ref_object}->{key}, 'Reclean' );
+    is( ${$ref_object}->{key}, 1, 'value stays the same' );
     isa_ok( $ref_object, 'My::ObjectRef' );
 }
 
@@ -224,7 +228,7 @@
     tainted_ok( $tied_hash_object->{value}, 'Gets dirty' );
     is( $tied_hash_object->{value}, 84, 'value stays the same' );
 
-    $tied_hash_object->{value} =~ /\A(\d+)\z/;
+    $tied_hash_object->{value} =~ /\A(\d+)\z/ or die;
     $tied_hash_object->{value} = $1;
 
     untainted_ok( $tied_hash_object->{value}, 'Reclean' );
@@ -248,7 +252,7 @@
     tainted_ok( $tied_array_object->[0], 'Gets dirty' );
     is( $tied_array_object->[0], 56, 'value stays the same' );
 
-    $tied_array_object->[0] =~ /\A(\d+)\z/;
+    $tied_array_object->[0] =~ /\A(\d+)\z/ or die;
     $tied_array_object->[0] = $1;
 
     untainted_ok( $tied_array_object->[0], 'Reclean' );
@@ -265,18 +269,18 @@
 
     my $tied_scalar_object = tie my $tied_scalar, 'My::TiedScalar';
 
-    $$tied_scalar_object = 63;
+    ${$tied_scalar_object} = 63;
 
-    untainted_ok( $$tied_scalar_object, 'Starts clean' );
+    untainted_ok( ${$tied_scalar_object}, 'Starts clean' );
     taint_deeply( \$tied_scalar );
-    tainted_ok( $$tied_scalar_object, 'Gets dirty' );
-    is( $$tied_scalar_object, 63, 'value stays the same' );
+    tainted_ok( ${$tied_scalar_object}, 'Gets dirty' );
+    is( ${$tied_scalar_object}, 63, 'value stays the same' );
 
-    $$tied_scalar_object =~ /\A(\d+)\z/;
-    $$tied_scalar_object = $1;
+    ${$tied_scalar_object} =~ /\A(\d+)\z/ or die;
+    ${$tied_scalar_object} = $1;
 
-    untainted_ok( $$tied_scalar_object, 'Reclean' );
-    is( $$tied_scalar_object, 63, 'value stays the same' );
+    untainted_ok( ${$tied_scalar_object}, 'Reclean' );
+    is( ${$tied_scalar_object}, 63, 'value stays the same' );
 }
 
 TAINT_AN_OVERLOADED_OBJECT: {
@@ -287,7 +291,7 @@
 
         sub as_string {
             my $self = shift;
-            return "%$self";
+            return "%{$self}";
         }
     }
 
@@ -300,7 +304,7 @@
     tainted_ok( $overloaded_object->{value}, 'Gets dirty' );
     is( $overloaded_object->{value}, 99, 'value stays the same' );
 
-    $overloaded_object->{value} =~ /\A(\d+)\z/;
+    $overloaded_object->{value} =~ /\A(\d+)\z/ or die;
     $overloaded_object->{value} = $1;
 
     untainted_ok( $overloaded_object->{value}, 'Reclean' );
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Test-Taint-1.04/t/tainted.t 
new/Test-Taint-1.06/t/tainted.t
--- old/Test-Taint-1.04/t/tainted.t     2004-02-04 07:33:37.000000000 +0100
+++ new/Test-Taint-1.06/t/tainted.t     2012-10-19 18:00:53.000000000 +0200
@@ -1,8 +1,11 @@
 #!perl -T
 
-use Test::More tests=>4;
+use warnings;
+use strict;
 
-BEGIN { use_ok( 'Test::Taint' ); }
+use Test::More tests => 6;
+
+use Test::Taint;
 
 my @keys = keys %ENV;
 my $key = shift @keys;
@@ -11,5 +14,16 @@
 ok( tainted($ENV{$key}), "\$ENV{$key} is tainted" );
 
 my $foo = 43;
-ok( !tainted($foo), "43 is not tainted" );
+ok( !tainted($foo), '43 is not tainted' );
+
+RESET_SIG_DIE: {
+    my $counter = 0;
+
+    local $SIG{__DIE__} = sub { $counter++ };
+
+    ok( tainted($ENV{$key}), "\$ENV{$key} is tainted" );
+    is($counter, 0, 'counter was not incremented (our die did not fire)');
 
+    eval { die 'validly' };
+    is($counter, 1, 'counter was incremented (our die fired properly)');
+}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Test-Taint-1.04/t/tainted_ok.t 
new/Test-Taint-1.06/t/tainted_ok.t
--- old/Test-Taint-1.04/t/tainted_ok.t  2004-02-04 07:32:20.000000000 +0100
+++ new/Test-Taint-1.06/t/tainted_ok.t  2012-10-19 18:00:32.000000000 +0200
@@ -1,5 +1,8 @@
 #!perl -T
 
+use warnings;
+use strict;
+
 use Test::Taint tests=>3;
 
 my @keys = keys %ENV;
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Test-Taint-1.04/t/tainted_ok_deeply.t 
new/Test-Taint-1.06/t/tainted_ok_deeply.t
--- old/Test-Taint-1.04/t/tainted_ok_deeply.t   2004-07-01 06:09:23.000000000 
+0200
+++ new/Test-Taint-1.06/t/tainted_ok_deeply.t   2012-10-19 18:17:54.000000000 
+0200
@@ -7,15 +7,15 @@
 
 taint_checking_ok('Taint checking is on');
 
-my %var = (
+my %vars = (
     HASH   => { key => 'value' },
     ARRAY  => [ 1..2 ],
     GLOB   => \*DATA,
-    SCALAR => \"can't taint this",
+    SCALAR => \q{u can't taint this},
     REF    => \{ another_key => 1 },
 );
 
-while(my($key, $value) = each %var) {
+while(my($key, $value) = each %vars) {
   is(
     ref $value,
     $key,
@@ -23,11 +23,11 @@
   );
 }
 
-untainted_ok_deeply( \%var, 'Everything should be untainted' );
+untainted_ok_deeply( \%vars, 'Everything should be untainted' );
 
-taint_deeply( \%var );
+taint_deeply( \%vars );
 
-tainted_ok_deeply( \%var, 'Everything should be tainted' );
+tainted_ok_deeply( \%vars, 'Everything should be tainted' );
 
 __DATA__
 i am glob

-- 
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to