aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorGreta Doci <gretadoci@gmail.com>2019-11-29 15:08:24 +0100
committerGreta Doci <gretadoci@gmail.com>2019-12-04 11:04:46 +0100
commit1110a93fc4ddb14b98431421731ed60d589a9e85 (patch)
tree736c8c29324678eec66e29778d5439f98aa1b384 /lib
parent6b97f6af48ba8dc029e616cf778a1cbcd0fea001 (diff)
downloadnextcloud-server-1110a93fc4ddb14b98431421731ed60d589a9e85.tar.gz
nextcloud-server-1110a93fc4ddb14b98431421731ed60d589a9e85.zip
fix filename size, add comment
Signed-off-by: Greta Doci <gretadoci@gmail.com>
Diffstat (limited to 'lib')
-rw-r--r--lib/private/Files/Storage/Common.php4
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/private/Files/Storage/Common.php b/lib/private/Files/Storage/Common.php
index 3bc14d35cd0..d1913c28d7e 100644
--- a/lib/private/Files/Storage/Common.php
+++ b/lib/private/Files/Storage/Common.php
@@ -535,7 +535,9 @@ abstract class Common implements Storage, ILockingStorage, IWriteStreamStorage {
}
}
- if (isset($fileName[255])) {
+ // 255 characters is the limit on common file systems (ext/xfs)
+ // oc_filecache has a 250 char length limit for the filename
+ if (isset($fileName[250])) {
throw new FileNameTooLongException();
}