summaryrefslogtreecommitdiffstats
path: root/lib/filestorage/local.php
diff options
context:
space:
mode:
authorRobin Appelman <icewind1991@gmail.com>2011-10-20 22:55:27 +0200
committerRobin Appelman <icewind1991@gmail.com>2011-10-20 22:55:27 +0200
commit3a937f79f72117be16d905d1fa421d93130a48a3 (patch)
treefde40e77dc3725d595f1b29938a130b9accee939 /lib/filestorage/local.php
parente9b6a1018db89fb23d6e52e529f80ce11da09bd0 (diff)
downloadnextcloud-server-3a937f79f72117be16d905d1fa421d93130a48a3.tar.gz
nextcloud-server-3a937f79f72117be16d905d1fa421d93130a48a3.zip
escape filenames for getMimeType
Diffstat (limited to 'lib/filestorage/local.php')
-rw-r--r--lib/filestorage/local.php1
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/filestorage/local.php b/lib/filestorage/local.php
index 8db0ffead4e..58c34e972de 100644
--- a/lib/filestorage/local.php
+++ b/lib/filestorage/local.php
@@ -140,6 +140,7 @@ class OC_Filestorage_Local extends OC_Filestorage{
} else if (OC_Helper::canExecute("file")) {
// it looks like we have a 'file' command,
// lets see it it does have mime support
+ $fspath=str_replace("'","\'",$fspath);
$fp = popen("file -i -b '{$this->datadir}$fspath' 2>/dev/null", "r");
$reply = fgets($fp);
pclose($fp);