[Catalyst-commits] r13872 - in Catalyst-Runtime/5.80/trunk: lib
t/aggregate
t0m at dev.catalyst.perl.org
t0m at dev.catalyst.perl.org
Fri Dec 17 00:49:54 GMT 2010
Author: t0m
Date: 2010-12-17 00:49:54 +0000 (Fri, 17 Dec 2010)
New Revision: 13872
Modified:
Catalyst-Runtime/5.80/trunk/lib/Catalyst.pm
Catalyst-Runtime/5.80/trunk/t/aggregate/live_engine_response_emptybody.t
Log:
Bad test failed to show bug.
Modified: Catalyst-Runtime/5.80/trunk/lib/Catalyst.pm
===================================================================
--- Catalyst-Runtime/5.80/trunk/lib/Catalyst.pm 2010-12-17 00:44:53 UTC (rev 13871)
+++ Catalyst-Runtime/5.80/trunk/lib/Catalyst.pm 2010-12-17 00:49:54 UTC (rev 13872)
@@ -1857,7 +1857,7 @@
}
# Content-Length
- if ( defined $response->body && !$response->content_length ) {
+ if ( defined $response->body && length $response->body && !$response->content_length ) {
# get the length from a filehandle
if ( blessed( $response->body ) && $response->body->can('read') || ref( $response->body ) eq 'GLOB' )
Modified: Catalyst-Runtime/5.80/trunk/t/aggregate/live_engine_response_emptybody.t
===================================================================
--- Catalyst-Runtime/5.80/trunk/t/aggregate/live_engine_response_emptybody.t 2010-12-17 00:44:53 UTC (rev 13871)
+++ Catalyst-Runtime/5.80/trunk/t/aggregate/live_engine_response_emptybody.t 2010-12-17 00:49:54 UTC (rev 13872)
@@ -20,7 +20,7 @@
{
my $res = request('/emptybody');
is $res->content, '';
- ok !$res->header('Content-Length');
+ ok !defined $res->header('Content-Length');
}
done_testing;
More information about the Catalyst-commits
mailing list