From 618918e5411e2e769ad5e8d44c5d1cc363b983b5 Mon Sep 17 00:00:00 2001 From: Jakub Narebski Date: Mon, 14 Aug 2006 02:15:22 +0200 Subject: [PATCH] gitweb: Skip comments in mime.types like file Signed-off-by: Jakub Narebski Signed-off-by: Junio C Hamano --- gitweb/gitweb.perl | 1 + 1 file changed, 1 insertion(+) diff --git a/gitweb/gitweb.perl b/gitweb/gitweb.perl index 4fe3fc7b4..52ae2aa86 100755 --- a/gitweb/gitweb.perl +++ b/gitweb/gitweb.perl @@ -858,6 +858,7 @@ sub mimetype_guess_file { my %mimemap; open(MIME, $mimemap) or return undef; while () { + next if m/^#/; # skip comments my ($mime, $exts) = split(/\t+/); if (defined $exts) { my @exts = split(/\s+/, $exts); -- 2.26.2