Commit Graph

121 Commits

Author SHA1 Message Date
Morris Jobke 27ba46c40e Merge pull request #1890 from nextcloud/downstream-25428
fixing php 32 bit (arm) filemtime on large file issue (#18971) (#25428)
2016-10-25 14:44:27 +02:00
Lukas Reschke 459477e2c3
Move function to LargeFileHelper
Signed-off-by: Lukas Reschke <lukas@statuscode.ch>
2016-10-25 12:00:57 +02:00
Boris Rybalkin cfc0d9249b
fixing php 32 bit (arm) filemtime on large file issue (#18971) (#25428)
* fixing php 32 bit (arm) filemtime on large file issue (#18971)

* cast to int
2016-10-25 11:43:17 +02:00
Lukas Reschke df3444493b
Remove not existent function call
- Removes a not existent function call
- Removes a fallback for Windows

Signed-off-by: Lukas Reschke <lukas@statuscode.ch>
2016-10-25 11:37:16 +02:00
Roeland Jago Douma e73a11d106
Fix permision mask
If we move a file from the temp part file to the original file we don't
need update permissions.

Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2016-10-24 21:45:00 +02:00
Morris Jobke 169faf8c32
Remove sensible information from exception message
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
2016-10-24 11:42:04 +02:00
Olivier Mehani 19ad058d06
Add message to NotSquareException thrown from Avatar
This prevents cryptic messages such as the following, from `user_ldap`:

     Could not set avatar for uid=user,ou=People,dc=example,dc=net, because:

Signed-off-by: Olivier Mehani <shtrom@ssji.net>

Add message to NotPermittedException thrown from Files\Nodes\Folder

Ditto.

Don't use translation macros here as this seems to be pretty low-level
errors that generally get caught and prettified, and I don't want to
unduly clog down the lower layers.

Signed-off-by: Olivier Mehani <shtrom@ssji.net>

fixup! Add message to NotPermittedException thrown from Files\Nodes\Folder
2016-10-24 11:27:27 +02:00
Roeland Jago Douma ab91fa2660 Merge pull request #1820 from nextcloud/4byte-filenames
Allow 4byte unicode filenames on supported platforms
2016-10-24 10:38:25 +02:00
Morris Jobke 2799b0a821 Merge pull request #1835 from nextcloud/downstream-24948
Move OC\Files\Storage\Shared to the right namespace
2016-10-20 23:48:15 +02:00
Vincent Petry 9e9fef46d9
Get rid of very old oc:// stream wrapper (#26381) 2016-10-20 20:46:30 +02:00
Joas Schilling 246bb9f33d
Move OC\Files\Storage\Shared to the right namespace 2016-10-20 20:27:44 +02:00
Robin Appelman 3a8e75a814
Allow 4byte unicode filenames on supported platforms
Signed-off-by: Robin Appelman <robin@icewind.nl>
2016-10-20 14:26:09 +02:00
Morris Jobke deb59d3d48 Merge pull request #1722 from nextcloud/hide-storage-warnings
hide storage wrapper warning for the readonly storage
2016-10-18 16:15:52 +02:00
Morris Jobke 4d2835802f
hide storage wrapper warning for the readonly storage
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
2016-10-13 14:37:31 +02:00
Robin Appelman 1484d01ff6
explicitly cast to int
Signed-off-by: Robin Appelman <robin@icewind.nl>
2016-10-12 16:12:39 +02:00
Robin Appelman 0d842e0550
optimize Folder::getById to use less queries
Signed-off-by: Robin Appelman <robin@icewind.nl>
2016-10-12 16:12:28 +02:00
Roeland Jago Douma 6807cb684f
avatar to appdata
* Fix AvatarTest

Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2016-10-05 11:00:16 +02:00
Roeland Jago Douma ac38a3a654
Add Tests
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2016-10-05 11:00:16 +02:00
Roeland Jago Douma 5d8b941fea
Initial AppData
* Introduce simpleFS
* Introduce IAppData
* Introduce AppData Factory to get your AppData folder
* Update FileDisplayResponse

* AppData implements a ISimpleRoot but lazy. So only if an apps starts
  to access data will stuff get initialized

Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2016-10-05 11:00:14 +02:00
Lukas Reschke c4d263199c Merge pull request #1521 from nextcloud/fix-mimetypedetect-hiddenfolder
Fix mimetype detection inside hidden folders (#26138)
2016-09-27 18:52:48 +02:00
Vincent Petry 9b4de310bd
Fix mimetype detection inside hidden folders (#26138)
Downstreaming of https://github.com/owncloud/core/pull/26138

Signed-off-by: Lukas Reschke <lukas@statuscode.ch>
2016-09-26 11:31:03 +02:00
Vincent Petry 1f21a132c7
Only use realpath for real directories (#26058)
In some cross-local-storage use cases, the Local storage is
instantiated with "/" as data directory. In such cases, calling
realpath() would cause PHP warnings when open_basedir is set.

This fix bypasses the realpath() call when dealing with a root storage.

Downstreaming of https://github.com/owncloud/core/pull/26058

Signed-off-by: Lukas Reschke <lukas@statuscode.ch>
2016-09-26 11:21:47 +02:00
Semih Serhat Karakaya cfc1c7cbd2 Update CachedMountInfo for user home storage
In getMountPointNode function rootId is not inside of the userFolder for home storage. We was searching '/user' folder in '/user/files' folder. So, it was return NULL. I moved searching part to parent folder. It solves everything. Also, obviously other storage types not affect then this change.

Related owncloud commit :
https://github.com/owncloud/core/pull/26017
2016-09-09 18:07:21 +03:00
Morris Jobke 5ac26d12f0 Merge pull request #1247 from nextcloud/storage-id-global-cache
more efficient querying of numeric storage ids
2016-09-08 21:09:14 +02:00
Robin Appelman e8e950a4d2
more efficient querying of numeric storage ids 2016-09-07 17:22:40 +02:00
Joas Schilling 24d90a4bb1
Correctly remove the charset from finfo mimetype 2016-09-05 09:48:22 +02:00
Vincent Petry 669b0bc2ae
Prevent error with orphaned shares when updating user mount cache 2016-08-30 19:49:23 +02:00
Jörn Friedrich Dreyer d5518735c9
always return numeric storage id as int, also check type equality in test asserts 2016-08-29 14:20:51 +02:00
Lukas Reschke 4d85ffc27c Merge pull request #1054 from nextcloud/less-cache-hits
Reduce the number of cache operations for dav operations
2016-08-27 22:44:29 +02:00
Roeland Jago Douma f805aff67c
Always use the LazyRoot 2016-08-26 12:13:34 +02:00
Robin Appelman fb88d66857 optimize getUserFolder for the common case 2016-08-25 17:22:25 +02:00
Robin Appelman 2693ae870e cache user folders 2016-08-25 17:22:25 +02:00
Robin Appelman b2d365734a cache root id in mountpoint 2016-08-25 17:22:25 +02:00
Robin Appelman a0c2342c20 prevent infinite recursion while getting storage from mount 2016-08-23 14:52:18 +02:00
Robin Appelman e316a7ade7 Allow jail wrappers to lazily initialize the source storage 2016-08-22 12:26:27 +02:00
Robin Appelman 5e44a2d868 Allow storage wrappers to lazily initialize the source storage 2016-08-22 12:23:55 +02:00
Lukas Reschke 67d016833d Merge pull request #810 from nextcloud/shared-cachethepropagatorinstance
Store the shared propagator instance
2016-08-10 17:24:57 +02:00
Vincent Petry 412b5c5407
Store the shared propagator instance
This instead of recreating it for every call.
2016-08-10 10:57:49 +02:00
Robin Appelman a999420c75 get shared storage storage id without setting up the storage 2016-08-09 15:52:13 +02:00
Thomas Müller f1cd68d713 Adding test case for getPathById including a jailed cache where root is just empty 2016-08-05 14:06:05 +02:00
Thomas Müller d252d79059 getJailedPath expects $path to have a trailing / - fixes #25464 2016-08-05 14:06:05 +02:00
Robin Appelman 81e103074e use limit instead of since when listing recent files 2016-07-22 15:20:55 +02:00
Robin Appelman e321ecd592 add recent files to node api 2016-07-22 14:39:32 +02:00
Robin Appelman d499f68fd7 Fix storage id with storage jail 2016-07-22 14:34:59 +02:00
Joas Schilling 0215b004da
Update with robin 2016-07-21 18:13:58 +02:00
Joas Schilling ba87db3fcc
Fix others 2016-07-21 18:13:57 +02:00
Robin Appelman 29eeeb2273 Save the files external mount id in the mount cache table 2016-07-13 16:34:08 +02:00
Morris Jobke c2d88a08b7
Remove unneeded checks if it runs on a Windows machine
* the setup check is still there
2016-07-08 15:55:17 +02:00
Thomas Müller d2d99a91a0 fix swift primary object store test (#25281)
* Wait for socket to be open

* Fix call on null

* Allow DB access for MountProviderTest

Makes unit tests pass when using object store, since their FS access is
actually oc_filecache DB access. It is currently not possible to mock
or bypass the logic from "SharedMount::verifyMountPoint()" triggered by
this test.
2016-07-05 08:54:51 +02:00
Hendrik Leppelsack 11be3d6276 remove png references in core 2016-07-01 16:36:37 +02:00