summaryrefslogtreecommitdiffstats
path: root/lib/private/files
diff options
context:
space:
mode:
authorThomas Müller <thomas.mueller@tmit.eu>2013-11-24 14:15:17 -0800
committerThomas Müller <thomas.mueller@tmit.eu>2013-11-24 14:15:17 -0800
commita2d4cd87d05392058d6837e8feea4fffb3e55faa (patch)
tree46d1c1b73ce5bc9764bda24224b663977ff74ee5 /lib/private/files
parent45db67d1744a278c5a00d6432e03de36514eb26f (diff)
parentbd3ead0d3181f74fd666b21ef83df8a6b2efc12d (diff)
downloadnextcloud-server-a2d4cd87d05392058d6837e8feea4fffb3e55faa.tar.gz
nextcloud-server-a2d4cd87d05392058d6837e8feea4fffb3e55faa.zip
Merge pull request #5874 from owncloud/fix-5845
Fix file uploads on Windows with SQL Server
Diffstat (limited to 'lib/private/files')
-rw-r--r--lib/private/files/cache/cache.php2
-rw-r--r--lib/private/files/cache/updater.php2
2 files changed, 2 insertions, 2 deletions
diff --git a/lib/private/files/cache/cache.php b/lib/private/files/cache/cache.php
index 8c34fa58540..ac50a988e32 100644
--- a/lib/private/files/cache/cache.php
+++ b/lib/private/files/cache/cache.php
@@ -507,7 +507,7 @@ class Cache {
$entry = $this->get($path);
if ($entry && $entry['mimetype'] === 'httpd/unix-directory') {
$id = $entry['fileid'];
- $sql = 'SELECT SUM(`size`), MIN(`size`) FROM `*PREFIX*filecache` '.
+ $sql = 'SELECT SUM(`size`) AS f1, MIN(`size`) AS f2 FROM `*PREFIX*filecache` '.
'WHERE `parent` = ? AND `storage` = ?';
$result = \OC_DB::executeAudited($sql, array($id, $this->getNumericStorageId()));
if ($row = $result->fetchRow()) {
diff --git a/lib/private/files/cache/updater.php b/lib/private/files/cache/updater.php
index da223567001..d45c5e17fc8 100644
--- a/lib/private/files/cache/updater.php
+++ b/lib/private/files/cache/updater.php
@@ -142,7 +142,7 @@ class Updater {
$cache->update($id, array('mtime' => $time, 'etag' => $storage->getETag($internalPath)));
if ($realPath !== '') {
$realPath = dirname($realPath);
- if($realPath === '/') {
+ if($realPath === DIRECTORY_SEPARATOR ) {
$realPath = "";
}
// check storage for parent in case we change the storage in this step