From: W. Trevor King Date: Thu, 29 Mar 2012 12:45:47 +0000 (-0400) Subject: gitweb: add `status` headers to git_feed() responses. X-Git-Url: https://git.ladys.computer/Gitweb/commitdiff_plain/fae278d5b93f925692be8fc843788e0fa2135de7546f002724522f2ec33278d9?hp=5f41702296a6412c8ad69a57f4771701fdfd4d257cc0dc1dfeea1a505ff2c25c gitweb: add `status` headers to git_feed() responses. The git_feed() method was not setting a `Status` header unless it was responding to an If-Modified-Since request with `304 Not Modified`. Now, when it is serving successful responses, it sets status to `200 OK`. Signed-off-by: W Trevor King Acked-by: Jakub Narebski Signed-off-by: Junio C Hamano --- diff --git a/gitweb.perl b/gitweb.perl index ae9d115..2d03fd7 100755 --- a/gitweb.perl +++ b/gitweb.perl @@ -7842,11 +7842,13 @@ sub git_feed { print $cgi->header( -type => $content_type, -charset => 'utf-8', - -last_modified => $latest_date{'rfc2822'}); + -last_modified => $latest_date{'rfc2822'}, + -status => '200 OK'); } else { print $cgi->header( -type => $content_type, - -charset => 'utf-8'); + -charset => 'utf-8', + -status => '200 OK'); } # Optimization: skip generating the body if client asks only