[SCM] Debian packaging of libsoap-lite-perl branch, master, updated. debian/0.714-1-28-g35698f8

Xavier Guimard x.guimard at free.fr
Sat May 18 18:37:36 UTC 2013


The following commit has been merged in the master branch:
commit 4122cc665be853252d20e2151d17204210094925
Author: Xavier Guimard <x.guimard at free.fr>
Date:   Sat May 18 20:08:02 2013 +0200

    Replace UNIVERSAL::isa by reftype as suggested by UNIVERSAL doc

diff --git a/debian/patches/hashref_crash.patch b/debian/patches/hashref_crash.patch
index 8264cdb..8c13944 100644
--- a/debian/patches/hashref_crash.patch
+++ b/debian/patches/hashref_crash.patch
@@ -1,26 +1,45 @@
 Author: Ashish Shukla <wahjava at members.fsf.org>
 Subject: use 'ref' rather than 'UNIVERSAL::isa'
-Reviewed-by: Nicholas Bamber <nicholas at periapt.co.uk>
+Reviewed-by: Xavier Guimard <x.guimard at free.fr>
 Last-Update: 2010-11-03
 Bug: http://rt.cpan.org/Ticket/Display.html?id=62667
 Bug-Debian: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=602056
+Last-Update: 2013-05-18
+
 --- a/lib/SOAP/Lite.pm
 +++ b/lib/SOAP/Lite.pm
-@@ -3820,13 +3820,13 @@
+@@ -3818,15 +3818,25 @@
+                 my($value) = $_->value; # take first value
+ 
                  # fillup parameters
-                 UNIVERSAL::isa($_[$param] => 'SOAP::Data')
-                     ? $_[$param]->SOAP::Data::value($value)
+-                UNIVERSAL::isa($_[$param] => 'SOAP::Data')
+-                    ? $_[$param]->SOAP::Data::value($value)
 -                    : UNIVERSAL::isa($_[$param] => 'ARRAY')
-+                    : (ref($_[$param] eq 'ARRAY'))
-                         ? (@{$_[$param]} = @$value)
+-                        ? (@{$_[$param]} = @$value)
 -                        : UNIVERSAL::isa($_[$param] => 'HASH')
-+                        : (ref($_[$param]) eq 'HASH')
-                             ? (%{$_[$param]} = %$value)
+-                            ? (%{$_[$param]} = %$value)
 -                            : UNIVERSAL::isa($_[$param] => 'SCALAR')
-+                            : (ref($_[$param]) eq 'SCALAR')
-                                 ? (${$_[$param]} = $$value)
+-                                ? (${$_[$param]} = $$value)
 -                                : ($_[$param] = $value)
-+                                : ($_[$param] = $value);
++                use Scalar::Util 'reftype';
++                if ( reftype( $_[$param] ) ) {
++                    if ( reftype( $_[$param] ) eq 'SCALAR' ) {
++                        ${ $_[$param] } = $$value;
++                    }
++                    elsif ( reftype( $_[$param] ) eq 'ARRAY' ) {
++                        @{ $_[$param] } = @$value;
++                    }
++                    elsif ( reftype( $_[$param] ) eq 'HASH' ) {
++                        if ( eval { $_[$param]->isa('SOAP::Data') } ) {
++                            $_[$param]->SOAP::Data::value($value);
++                        }
++                        else { %{ $_[$param] } = %$value; }
++                    }
++                    else { $_[$param] = $value; }
++                }
++                else {
++                    $_[$param] = $value;
++                }
              }
          }
      }

-- 
Debian packaging of libsoap-lite-perl



More information about the Pkg-perl-cvs-commits mailing list