Commit Graph

15 Commits

Author SHA1 Message Date
Christoph Wurst 5bf3d1bb38
Update license headers
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2019-12-05 15:38:45 +01:00
Robin Appelman 74c6beb603
dont set folder size to negative values during propagation
normally this shouldn't be a problem, but cache/storage desync might cause this
so this adds some failsafe to ensure we dont corrupt the cache further

the minimum value is set to -1 instead of 0 in order to triger a background scan
on the folder and figure out the size properly

Signed-off-by: Robin Appelman <robin@icewind.nl>
2019-11-26 12:05:30 +01:00
Morris Jobke 60681decdd
Merge pull request #12865 from nextcloud/fix/do_not_propogate_in_appdata
No need to propogate changes in appdata
2018-12-06 08:50:22 +01:00
Roeland Jago Douma 72f3882d4b
No need to propogate changes in appdata
Right now we propogate a lof of changes in appdata. So for example we
propogate each and every preview that is added to the system. This has
no real added value as far as I can tell.

Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2018-12-05 22:06:19 +01:00
Roeland Jago Douma f7a1ed8656
Only execute query in propagateChange once
The second execute statement should be inside the if block. Else it gets
executed twice which makes no sense.

Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2018-12-05 20:32:02 +01:00
Joas Schilling bb352fb667
Use the defined func()->count() instead of manual counting
Signed-off-by: Joas Schilling <coding@schilljs.com>
2018-11-08 15:44:45 +01:00
Morris Jobke 0eebff152a
Update license headers
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
2017-11-06 16:56:19 +01:00
Lukas Reschke 3d2600b039
Add Phan plugin to check for SQL injections
This adds a phan plugin which checks for SQL injections on code using our QueryBuilder, while it isn't perfect it should already catch most potential issues.

As always, static analysis will sometimes have false positives and this is also here the case. So in some cases the analyzer just doesn't know if something is potential user input or not, thus I had to add some `@suppress SqlInjectionChecker` in front of those potential injections.

The Phan plugin hasn't the most awesome code but it works and I also added a file with test cases.

Signed-off-by: Lukas Reschke <lukas@statuscode.ch>
2017-07-20 22:48:13 +02:00
Robin Appelman 7be62d083e
explicitly cast mtime to int
Signed-off-by: Robin Appelman <robin@icewind.nl>
2016-11-03 14:36:46 +01: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 fce19d22d9 fix mtime propagation on sqlite 2016-06-02 15:43:43 +02:00
Robin Appelman 9fb44e34af add propagator batching 2016-06-02 15:07:47 +02:00
Robin Appelman dbfdc6282a
do propagation in a single query 2016-04-25 16:18:59 +02:00
Roeland Jago Douma dedf392751
Move \OC\Files to PSR-4 2016-04-24 21:37:35 +02:00