提交 d4c8c55f 编写于 作者: J Junio C Hamano

Merge branch 'ln/gitweb-mime-types-split-at-blank'

* ln/gitweb-mime-types-split-at-blank:
  gitweb: allow space as delimiter in mime.types
......@@ -3562,12 +3562,9 @@ sub mimetype_guess_file {
open(my $mh, '<', $mimemap) or return undef;
while (<$mh>) {
next if m/^#/; # skip comments
my ($mimetype, $exts) = split(/\t+/);
if (defined $exts) {
my @exts = split(/\s+/, $exts);
foreach my $ext (@exts) {
$mimemap{$ext} = $mimetype;
}
my ($mimetype, @exts) = split(/\s+/);
foreach my $ext (@exts) {
$mimemap{$ext} = $mimetype;
}
}
close($mh);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册