diff options
author | Robin Appelman <icewind1991@gmail.com> | 2010-10-03 23:07:55 +0000 |
---|---|---|
committer | Robin Appelman <icewind1991@gmail.com> | 2010-10-03 23:07:55 +0000 |
commit | 494d88a4353799ae2fbc2631578664715c063c7e (patch) | |
tree | e79312221c255766eb850dc74c62303cc1bdb8df /inc | |
parent | 44946e208d22b0175fd14a3b1ac2a388bc3e58ba (diff) | |
download | nextcloud-server-494d88a4353799ae2fbc2631578664715c063c7e.tar.gz nextcloud-server-494d88a4353799ae2fbc2631578664715c063c7e.zip |
fix bug in detecting mountpoints of file storages within chrooted filesystem
Diffstat (limited to 'inc')
-rw-r--r-- | inc/lib_filesystem.php | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/inc/lib_filesystem.php b/inc/lib_filesystem.php index c8cbd1cb80d..60201825e06 100644 --- a/inc/lib_filesystem.php +++ b/inc/lib_filesystem.php @@ -169,9 +169,15 @@ class OC_FILESYSTEM{ if(substr($path,0,1)!=='/'){ $path='/'.$path; } + if(substr($path,-1)!=='/'){ + $path=$path.'/'; + } $path=self::$fakeRoot.$path; $foundMountPoint=''; foreach(self::$storages as $mountpoint=>$storage){ + if(substr($mountpoint,-1)!=='/'){ + $mountpoint=$mountpoint.'/'; + } if($mountpoint==$path){ return $mountpoint; } |