Commit f18078142ee5bb00a45d5a69e87d34e96ca76547
1 parent
7cdf4216
Stop using mime_content_type - it's giving incorrect answers on Windows.
git-svn-id: https://kt-dms.svn.sourceforge.net/svnroot/kt-dms/trunk@4477 c91229c3-7414-0410-bfa2-8a42b809f60b
Showing
1 changed file
with
0 additions
and
7 deletions
lib/mime.inc.php
| @@ -82,13 +82,6 @@ class KTMime { | @@ -82,13 +82,6 @@ class KTMime { | ||
| 82 | $sType = finfo_file($res, $sFileName); | 82 | $sType = finfo_file($res, $sFileName); |
| 83 | } | 83 | } |
| 84 | 84 | ||
| 85 | - if (!$sType && function_exists('mime_content_type')) { | ||
| 86 | - $sFile = ini_get('mime_magic.magicfile'); | ||
| 87 | - if (file_exists($sFile)) { | ||
| 88 | - $sType = mime_content_type($sFileName); | ||
| 89 | - } | ||
| 90 | - } | ||
| 91 | - | ||
| 92 | if (!$sType) { | 85 | if (!$sType) { |
| 93 | if (file_exists('/usr/bin/file')) { | 86 | if (file_exists('/usr/bin/file')) { |
| 94 | $aCmd = array('/usr/bin/file', '-bi', $sFileName); | 87 | $aCmd = array('/usr/bin/file', '-bi', $sFileName); |