Subject: [PATCH 7/9] gitweb: Skip comments in mime.types like file

From: Jakub Narebski <[email-masked]>
Date: Mon, 14 Aug 2006 02:15:22 +0200

Signed-off-by: Jakub Narebski <[email-masked]>
---
 gitweb/gitweb.perl |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/gitweb/gitweb.perl b/gitweb/gitweb.perl
index 4fe3fc7..52ae2aa 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 (<MIME>) {
+		next if m/^#/; # skip comments
 		my ($mime, $exts) = split(/\t+/);
 		if (defined $exts) {
 			my @exts = split(/\s+/, $exts);
-- 
1.4.1.1