Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
die_coolen_jungs
our_own_cloud_project
Commits
daf5f793
Commit
daf5f793
authored
Apr 29, 2016
by
Morris Jobke
Browse files
Merge pull request #24351 from owncloud/capped-normalized-cache
cap the normalized path cache
parents
66ebc2ee
d850a764
Changes
1
Hide whitespace changes
Inline
Side-by-side
lib/private/Files/Filesystem.php
View file @
daf5f793
...
...
@@ -58,6 +58,7 @@
namespace
OC\Files
;
use
OC\Cache\CappedMemoryCache
;
use
OC\Files\Config\MountProviderCollection
;
use
OC\Files\Mount\MountPoint
;
use
OC\Files\Storage\StorageFactory
;
...
...
@@ -81,7 +82,7 @@ class Filesystem {
static
private
$usersSetup
=
array
();
static
private
$normalizedPathCache
=
array
()
;
static
private
$normalizedPathCache
=
null
;
static
private
$listeningForProviders
=
false
;
...
...
@@ -794,6 +795,10 @@ class Filesystem {
* @return string
*/
public
static
function
normalizePath
(
$path
,
$stripTrailingSlash
=
true
,
$isAbsolutePath
=
false
)
{
if
(
is_null
(
self
::
$normalizedPathCache
))
{
self
::
$normalizedPathCache
=
new
CappedMemoryCache
();
}
/**
* FIXME: This is a workaround for existing classes and files which call
* this function with another type than a valid string. This
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment