diff options
author | Robin Appelman <icewind@owncloud.com> | 2012-09-30 03:58:58 +0200 |
---|---|---|
committer | Robin Appelman <icewind@owncloud.com> | 2012-09-30 03:58:58 +0200 |
commit | 258782584e490b92ccfcf032921aa7062a28da9f (patch) | |
tree | 1f3b8686c838e1d0f9891b9118fc2458321e9ca8 /lib/helper.php | |
parent | f8eebcbb011269a36fe4b10f21b73dec4b076bff (diff) | |
download | nextcloud-server-258782584e490b92ccfcf032921aa7062a28da9f.tar.gz nextcloud-server-258782584e490b92ccfcf032921aa7062a28da9f.zip |
fix mimetype detection using the 'file' command in some edge cases
Diffstat (limited to 'lib/helper.php')
-rw-r--r-- | lib/helper.php | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/helper.php b/lib/helper.php index 8e578735f4c..908a61b5a2d 100644 --- a/lib/helper.php +++ b/lib/helper.php @@ -370,6 +370,7 @@ class OC_Helper { //trim the character set from the end of the response $mimeType=substr($reply,0,strrpos($reply,' ')); + $mimeType=substr($mimeType,0,strrpos($mimeType,"\n")); //trim ; if (strpos($mimeType, ';') !== false) { |