diff -Nru libphp-serialization-perl-0.33/Changes libphp-serialization-perl-0.34/Changes --- libphp-serialization-perl-0.33/Changes 2009-07-14 21:27:23.000000000 +0100 +++ libphp-serialization-perl-0.34/Changes 2010-03-18 22:23:41.000000000 +0000 @@ -1,5 +1,9 @@ Revision history for Perl extension PHP::Serialization +0.34 2010-03-18 + - Fix keys and values like '010' being serialized as strings as expected + rather than being turned into ints. (RT#48594) + 0.33 2009-07-14 - Added ability to store the order of the keys on decoding PHP assoc array (Alexander Bassilov) diff -Nru libphp-serialization-perl-0.33/debian/changelog libphp-serialization-perl-0.34/debian/changelog --- libphp-serialization-perl-0.33/debian/changelog 2010-05-09 20:12:43.000000000 +0100 +++ libphp-serialization-perl-0.34/debian/changelog 2010-03-28 15:26:15.000000000 +0100 @@ -1,3 +1,19 @@ +libphp-serialization-perl (0.34-1) unstable; urgency=low + + [ Ryan Niebur ] + * Update jawnsy's email address + + [ Jonathan Yu ] + * New upstream release + + [ gregor herrmann ] + * Convert to source format 3.0 (quilt). + * Set Standards-Version to 3.8.4 (no changes). + * Add /me to Uploaders. + * Update formatting for debian/copyright. + + -- gregor herrmann Sun, 28 Mar 2010 16:26:13 +0200 + libphp-serialization-perl (0.33-1) unstable; urgency=low * New upstream release diff -Nru libphp-serialization-perl-0.33/debian/control libphp-serialization-perl-0.34/debian/control --- libphp-serialization-perl-0.33/debian/control 2010-05-09 20:12:43.000000000 +0100 +++ libphp-serialization-perl-0.34/debian/control 2010-03-28 15:22:50.000000000 +0100 @@ -6,8 +6,9 @@ Maintainer: Debian Perl Group Uploaders: Krzysztof Krzyzaniak (eloy) , Jose Luis Rivas , Ansgar Burchardt , - Gunnar Wolf , Jonathan Yu -Standards-Version: 3.8.2 + Gunnar Wolf , Jonathan Yu , + gregor herrmann +Standards-Version: 3.8.4 Homepage: http://search.cpan.org/dist/PHP-Serialization/ Vcs-Svn: svn://svn.debian.org/pkg-perl/trunk/libphp-serialization-perl/ Vcs-Browser: http://svn.debian.org/viewsvn/pkg-perl/trunk/libphp-serialization-perl/ diff -Nru libphp-serialization-perl-0.33/debian/copyright libphp-serialization-perl-0.34/debian/copyright --- libphp-serialization-perl-0.33/debian/copyright 2010-05-09 20:12:43.000000000 +0100 +++ libphp-serialization-perl-0.34/debian/copyright 2010-03-28 15:24:15.000000000 +0100 @@ -1,30 +1,32 @@ -Format-Specification: - http://wiki.debian.org/Proposals/CopyrightFormat?action=recall&rev=196 -Upstream-Maintainer: Tomas Doran -Upstream-Source: http://search.cpan.org/dist/PHP-Serialization/ -Upstream-Name: PHP-Serialization +Format-Specification: http://svn.debian.org/wsvn/dep/web/deps/dep5.mdwn?op=file&rev=135 +Maintainer: Tomas Doran +Source: http://search.cpan.org/dist/PHP-Serialization/ +Name: PHP-Serialization Files: * Copyright: 2003, Jesse Brown -License-Alias: Perl -License: GPL-1+ | Artistic +License: Artistic or GPL-1+ Files: debian/* -Copyright: 2009, Jonathan Yu +Copyright: 2008, 2009, Ansgar Burchardt + 2008, Gunnar Wolf 2008, Krzysztof Krzyzaniak (eloy) -License: GPL-1+ | Artistic + 2009-2010, Jonathan Yu + 2010, gregor herrmann +License: Artistic or GPL-1+ License: Artistic - This program is free software; you can redistribute it and/or modify - it under the terms of the Artistic License, which comes with Perl. - On Debian GNU/Linux systems, the complete text of the Artistic License - can be found in `/usr/share/common-licenses/Artistic' + This program is free software; you can redistribute it and/or modify + it under the terms of the Artistic License, which comes with Perl. + . + On Debian GNU/Linux systems, the complete text of the Artistic License + can be found in `/usr/share/common-licenses/Artistic' License: GPL-1+ - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 1, or (at your option) - any later version. - On Debian GNU/Linux systems, the complete text of the GNU General - Public License can be found in `/usr/share/common-licenses/GPL' - + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 1, or (at your option) + any later version. + . + On Debian GNU/Linux systems, the complete text of the GNU General + Public License can be found in `/usr/share/common-licenses/GPL' diff -Nru libphp-serialization-perl-0.33/debian/source/format libphp-serialization-perl-0.34/debian/source/format --- libphp-serialization-perl-0.33/debian/source/format 1970-01-01 01:00:00.000000000 +0100 +++ libphp-serialization-perl-0.34/debian/source/format 2010-05-09 20:12:44.000000000 +0100 @@ -0,0 +1 @@ +3.0 (quilt) diff -Nru libphp-serialization-perl-0.33/lib/PHP/Serialization.pm libphp-serialization-perl-0.34/lib/PHP/Serialization.pm --- libphp-serialization-perl-0.33/lib/PHP/Serialization.pm 2009-07-14 21:27:37.000000000 +0100 +++ libphp-serialization-perl-0.34/lib/PHP/Serialization.pm 2010-03-18 22:23:41.000000000 +0000 @@ -8,7 +8,7 @@ use vars qw/$VERSION @ISA @EXPORT_OK/; -$VERSION = '0.33'; +$VERSION = '0.34'; @ISA = qw(Exporter); @EXPORT_OK = qw(unserialize serialize); @@ -377,7 +377,7 @@ return $self->_encode('obj', $val); } elsif ( ! ref($val) ) { - if ( $val =~ /^-?\d{1,10}$/ && abs($val) < 2**31 ) { + if ( $val =~ /^-?(?:[0-9]|[1-9]\d{1,10})$/ && abs($val) < 2**31 ) { return $self->_encode('int', $val); } elsif ( $val =~ /^-?\d+\.\d*$/ && !$iskey) { diff -Nru libphp-serialization-perl-0.33/MANIFEST libphp-serialization-perl-0.34/MANIFEST --- libphp-serialization-perl-0.33/MANIFEST 2009-07-14 21:29:28.000000000 +0100 +++ libphp-serialization-perl-0.34/MANIFEST 2010-03-18 22:24:10.000000000 +0000 @@ -3,7 +3,6 @@ Makefile.PL MANIFEST This list of files README -sort_hashes.patch t/01use.t t/02basic.t t/03largeints.t @@ -13,4 +12,5 @@ t/07croak.t t/08incompletestringRT44700.t t/09floatindexRT42029.t +t/10intRT48594.t META.yml Module meta-data (added by MakeMaker) diff -Nru libphp-serialization-perl-0.33/META.yml libphp-serialization-perl-0.34/META.yml --- libphp-serialization-perl-0.33/META.yml 2009-07-14 21:29:27.000000000 +0100 +++ libphp-serialization-perl-0.34/META.yml 2010-03-18 22:24:10.000000000 +0000 @@ -1,6 +1,6 @@ --- #YAML:1.0 name: PHP-Serialization -version: 0.33 +version: 0.34 abstract: simple flexible means of converting the output of PHP's serialize() into the equivalent Perl memory structure, and vice versa. author: - Jesse Brown @@ -15,7 +15,7 @@ directory: - t - inc -generated_by: ExtUtils::MakeMaker version 6.50 +generated_by: ExtUtils::MakeMaker version 6.54 meta-spec: url: http://module-build.sourceforge.net/META-spec-v1.4.html version: 1.4 diff -Nru libphp-serialization-perl-0.33/sort_hashes.patch libphp-serialization-perl-0.34/sort_hashes.patch --- libphp-serialization-perl-0.33/sort_hashes.patch 2009-07-05 16:02:25.000000000 +0100 +++ libphp-serialization-perl-0.34/sort_hashes.patch 1970-01-01 01:00:00.000000000 +0100 @@ -1,26 +0,0 @@ -348a349,350 -> my $sorthash; -> -350c352 -< my ($self, $val, $iskey) = @_; ---- -> my ($self, $val, $iskey, $shash) = @_; -351a354 -> $sorthash=$shash if defined $shash; -372a376 -> return $self->_sort_hash_encode($val) if (($type eq 'HASH') and ($sorthash)); -380a385,398 -> sub _sort_hash_encode { -> my ($self, $val) = @_; -> -> my $buffer = ''; -> my @hsort = sort keys %{$val}; -> $buffer .= sprintf('a:%d:',scalar(@hsort)) . '{'; -> for (@hsort) { -> $buffer .= $self->encode($_,1); -> $buffer .= $self->encode($$val{$_}); -> } -> $buffer .= '}'; -> return $buffer; -> } -> diff -Nru libphp-serialization-perl-0.33/t/10intRT48594.t libphp-serialization-perl-0.34/t/10intRT48594.t --- libphp-serialization-perl-0.33/t/10intRT48594.t 1970-01-01 01:00:00.000000000 +0100 +++ libphp-serialization-perl-0.34/t/10intRT48594.t 2010-03-18 22:15:44.000000000 +0000 @@ -0,0 +1,15 @@ +#!/usr/bin/env perl +use strict; +use warnings; + +use PHP::Serialization; +use Test::More tests => 2; + +my $a = {'020' => '001'}; +my $str = PHP::Serialization::serialize( $a ); +is($str,'a:1:{s:3:"020";s:3:"001";}', 'Keys and vals are string for 0 prefixed numbers'); + +my $b = {'0' => '0'}; +$str = PHP::Serialization::serialize( $b ); +is($str,'a:1:{i:0;i:0;}', 'Keys and vals are ints for 0'); +