From b2da3f40fb7650a658b6ed1a15c81704d91b2831 Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Thu, 17 Apr 2014 21:30:21 +0000 Subject: cgi: include HTTP status in error message body This makes it slightly easier for out-of-the-box curl users since curl does not report or show the error by default. --- public-inbox.cgi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'public-inbox.cgi') diff --git a/public-inbox.cgi b/public-inbox.cgi index 9d60d1fc..bd592ce3 100755 --- a/public-inbox.cgi +++ b/public-inbox.cgi @@ -95,7 +95,7 @@ sub main { sub r404 { r("404 Not Found") } # simple response for errors -sub r { [ $_[0], { 'Content-Type' => 'text/plain' }, '' ] } +sub r { [ $_[0], { 'Content-Type' => 'text/plain' }, $_[0]."\n" ] } # returns undef if valid, array ref response if invalid sub invalid_list { -- cgit v1.2.3-24-ge0c7