r20669 - in /trunk/librest-application-perl/debian: changelog patches/header_additive patches/series
djpig at users.alioth.debian.org
djpig at users.alioth.debian.org
Tue Jun 3 21:29:54 UTC 2008
Author: djpig
Date: Tue Jun 3 21:29:53 2008
New Revision: 20669
URL: http://svn.debian.org/wsvn/pkg-perl/?sc=1&rev=20669
Log:
New patch:
+ header_additive: Fix header() to act according to documentation
when called more than once.
Added:
trunk/librest-application-perl/debian/patches/header_additive
Modified:
trunk/librest-application-perl/debian/changelog
trunk/librest-application-perl/debian/patches/series
Modified: trunk/librest-application-perl/debian/changelog
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/librest-application-perl/debian/changelog?rev=20669&op=diff
==============================================================================
--- trunk/librest-application-perl/debian/changelog (original)
+++ trunk/librest-application-perl/debian/changelog Tue Jun 3 21:29:53 2008
@@ -4,6 +4,8 @@
* New patches:
+ perldoc_fixes: fix several syntax problems in POD and
some typos.
+ + header_additive: Fix header() to act according to documentation
+ when called more than once.
-- Frank Lichtenheld <djpig at debian.org> Tue, 03 Jun 2008 23:02:41 +0200
Added: trunk/librest-application-perl/debian/patches/header_additive
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/librest-application-perl/debian/patches/header_additive?rev=20669&op=file
==============================================================================
--- trunk/librest-application-perl/debian/patches/header_additive (added)
+++ trunk/librest-application-perl/debian/patches/header_additive Tue Jun 3 21:29:53 2008
@@ -1,0 +1,32 @@
+Index: librest-application-perl/lib/REST/Application.pm
+===================================================================
+--- librest-application-perl.orig/lib/REST/Application.pm 2008-06-03 23:16:33.000000000 +0200
++++ librest-application-perl/lib/REST/Application.pm 2008-06-03 23:24:45.000000000 +0200
+@@ -305,9 +305,9 @@
+ # Arguments can be passed in as a hash-ref or as an even sized list.
+ if (@_) {
+ if (@_%2 == 0) { # even-sized list, must be hash
+- %{ $self->{__header} } = @_;
++ %{ $self->{__header} } = ( %{$self->{__header}}, @_ );
+ } elsif (ref($_[0]) eq 'HASH') { # First item must be a hash reference
+- $self->{__header} = shift;
++ %{ $self->{__header} } = ( %{$self->{__header}}, %{$_[0]} );
+ } else {
+ croak "Expected even-sized list or hash reference.";
+ }
+Index: librest-application-perl/t/01-basic.t
+===================================================================
+--- librest-application-perl.orig/t/01-basic.t 2008-06-03 23:18:09.000000000 +0200
++++ librest-application-perl/t/01-basic.t 2008-06-03 23:18:50.000000000 +0200
+@@ -283,8 +283,10 @@
+ my %hash = $rest->header();
+ is_deeply(\%hash, {}, "Retrieving default header values.");
+ $rest->header(-type => 'text/html', -foobar => 5);
++ $rest->header(-baz => 10);
+ %hash = $rest->header();
+- is_deeply(\%hash, {-type => 'text/html', -foobar => 5}, "Retrieving custom header values.");
++ is_deeply(\%hash, {-type => 'text/html', -foobar => 5, -baz => 10},
++ "Retrieving custom header values.");
+ }
+
+ # TEST: resetHeader()
Modified: trunk/librest-application-perl/debian/patches/series
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/librest-application-perl/debian/patches/series?rev=20669&op=diff
==============================================================================
--- trunk/librest-application-perl/debian/patches/series (original)
+++ trunk/librest-application-perl/debian/patches/series Tue Jun 3 21:29:53 2008
@@ -1,1 +1,2 @@
+header_additive
perldoc_fixes
More information about the Pkg-perl-cvs-commits
mailing list