Subject: | libwww-perl 5.815 breaks test number 28 |
It seems that the libwww-perl change
a0d23e8007088eaa3bf0f1aca828ec8e2456fa39 between the releases 5.814 and
5.815 breaks the test number 28. Previously a died collect callback
caused to create a HTTP::Response with the error code 500, but nowadays
only the HTTP header X-Died is set. The attached patch corrects this to
the old behaviour (creating a 500 response).
This and the patch from http://rt.cpan.org/Ticket/Display.html?id=41946
is needed to get the test suite of LWPx::ParanoidAgent running again.
Regards,
Slaven
Subject: | 0002-LWP-5.815-changed-response-of-failed-collect-callb.patch |
From e585cd16c0eb30ce4568a280329ab5f8b4ff5a39 Mon Sep 17 00:00:00 2001
From: Slaven Rezic <slaven@rezic.de>
Date: Fri, 20 Feb 2009 15:55:59 +0100
Subject: [PATCH] LWP 5.815 changed response of failed collect() callbacks: previously
it generated a 500 HTTP::Response object, now it just sets the X-Died
header. This caused test number 28 to fail. This patch fixes this by
restoring the old behaviour again.
---
lib/LWPx/Protocol/http_paranoid.pm | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
diff --git a/lib/LWPx/Protocol/http_paranoid.pm b/lib/LWPx/Protocol/http_paranoid.pm
index 0d00b6f..aae5671 100644
--- a/lib/LWPx/Protocol/http_paranoid.pm
+++ b/lib/LWPx/Protocol/http_paranoid.pm
@@ -353,6 +353,10 @@ sub request
$complete++ if !$n;
return \$buf;
} );
+ if ($response->header('X-Died')) {
+ $response = HTTP::Response->new(&HTTP::Status::RC_INTERNAL_SERVER_ERROR,
+ $response->header('X-Died'));
+ }
$drop_connection++ unless $complete;
_set_time_remain();
--
1.5.6.5