Photos
Blog
Projects
vanrenterghem.biz
projects
/
git.ikiwiki.info.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Added a comment: It was an Apache problem...
[git.ikiwiki.info.git]
/
IkiWiki
/
Plugin
/
filecheck.pm
diff --git
a/IkiWiki/Plugin/filecheck.pm
b/IkiWiki/Plugin/filecheck.pm
index cdea5c706f4085686bf20b5e7a09283792137c31..6e65283983b472fe26c86351fb6572ec5ae51865 100644
(file)
--- a/
IkiWiki/Plugin/filecheck.pm
+++ b/
IkiWiki/Plugin/filecheck.pm
@@
-150,7
+150,7
@@
sub match_mimetype ($$;@) {
chomp $mimetype;
close $file_h;
}
chomp $mimetype;
close $file_h;
}
- if (! defined $mimetype
|| $mimetype !~s /;.*//
) {
+ if (! defined $mimetype) {
# Fall back to default value.
$mimetype=File::MimeInfo::Magic::default($file)
if $mimeinfo_ok;
# Fall back to default value.
$mimetype=File::MimeInfo::Magic::default($file)
if $mimeinfo_ok;
@@
-158,6
+158,8
@@
sub match_mimetype ($$;@) {
$mimetype="unknown";
}
}
$mimetype="unknown";
}
}
+ # Ignore any parameters, we only want the type itself
+ $mimetype =~ s/;.*//;
my $regexp=IkiWiki::glob2re($wanted);
if ($mimetype!~$regexp) {
my $regexp=IkiWiki::glob2re($wanted);
if ($mimetype!~$regexp) {