Skip to content

Commit

Permalink
gitweb: Don't use Content-Encoding: header in git_snapshot
Browse files Browse the repository at this point in the history
Do not use Content-Encoding: HTTP header in git_snapshot, using
instead type according to the snapshot type (compression type).
Some of web browser take Content-Encoding: to be _transparent_
also for downloading, and store decompressed file (with incorrect
compression suffix) on download.

Signed-off-by: Jakub Narebski <jnareb@gmail.com>
Signed-off-by: Junio C Hamano <junkio@cox.net>
  • Loading branch information
Jakub Narebski authored and Junio C Hamano committed Dec 12, 2006
1 parent 6f98725 commit 9aa1757
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions gitweb/gitweb.perl
Original file line number Diff line number Diff line change
Expand Up @@ -3414,8 +3414,7 @@ sub git_snapshot {
my $filename = basename($project) . "-$hash.tar.$suffix";

print $cgi->header(
-type => 'application/x-tar',
-content_encoding => $ctype,
-type => "application/$ctype",
-content_disposition => 'inline; filename="' . "$filename" . '"',
-status => '200 OK');

Expand Down

0 comments on commit 9aa1757

Please sign in to comment.