summaryrefslogtreecommitdiffstats
path: root/apps/files_sharing/lib_share.php
diff options
context:
space:
mode:
authorMichael Gapczynski <GapczynskiM@gmail.com>2012-06-14 12:27:30 -0400
committerMichael Gapczynski <GapczynskiM@gmail.com>2012-06-14 12:27:30 -0400
commit6e15b231b081183cae8d1cdfb482d76d2f3c2873 (patch)
treeac09b7b0e68250aa1ed7aea2af40ca8ad24dc4de /apps/files_sharing/lib_share.php
parent47c03a0effbe036e644da8ae2dee65f12a6e6c84 (diff)
downloadnextcloud-server-6e15b231b081183cae8d1cdfb482d76d2f3c2873.tar.gz
nextcloud-server-6e15b231b081183cae8d1cdfb482d76d2f3c2873.zip
Check for '\' as well when searching for parent folders, because Windows returns '\' for dirname()
Diffstat (limited to 'apps/files_sharing/lib_share.php')
-rw-r--r--apps/files_sharing/lib_share.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/apps/files_sharing/lib_share.php b/apps/files_sharing/lib_share.php
index 356c958b6ce..31170f07fd1 100644
--- a/apps/files_sharing/lib_share.php
+++ b/apps/files_sharing/lib_share.php
@@ -276,7 +276,7 @@ class OC_Share {
$userDirectory = substr($target, 0, strpos($target, "files") + 5);
$target = dirname($target);
$result = array();
- while ($target != "" && $target != "/" && $target != "." && $target != $userDirectory) {
+ while ($target != "" && $target != "/" && $target != "." && $target != $userDirectory && $target != "\\") {
// Check if the parent directory of this target location is shared
$result = $query->execute(array($target))->fetchAll();
if (count($result) > 0) {