1
0
Fork 0
Commit Graph

153 Commits

Author SHA1 Message Date
chylex d2e5094d13
Revert "Merge pull request #3057 from nextcloud/bugfix/vfs-windows-lnk-files-freeze-issue" 2022-02-07 01:17:05 +01:00
Matthieu Gallien d2f2e3305a avoid being stuck trying to create placeholder for existing file
id sync db think a file is cirtual (empty placeholder) but file system
has a real file (non empty file) once the server has a modified version
we can no longer update it

state of file on disk takes precedence over sync DB to allow recovery

Signed-off-by: Matthieu Gallien <matthieu.gallien@nextcloud.com>
2021-07-09 12:37:47 +00:00
Matthieu Gallien 8f5b88acd5 improve error message in case of trailing space in directory name
Signed-off-by: Matthieu Gallien <matthieu.gallien@nextcloud.com>
2021-07-02 10:50:31 +00:00
allexzander 99f6e82290 Fix review comments.
Signed-off-by: allexzander <blackslayer4@gmail.com>
2021-07-01 11:59:21 +03:00
allexzander 6ce5279b6c Fix review comments.
Signed-off-by: allexzander <blackslayer4@gmail.com>
2021-07-01 11:59:21 +03:00
allexzander 22eba41cb8 Do not process non-directories and non-virtual files. Wipe empty online-only folder based on its pinState.
Signed-off-by: allexzander <blackslayer4@gmail.com>
2021-07-01 11:59:21 +03:00
allexzander c5982143aa Refactoring.
Signed-off-by: allexzander <blackslayer4@gmail.com>
2021-07-01 11:59:21 +03:00
allexzander 48aefc1983 Fix VFS crash and false conflict on local new.
Signed-off-by: allexzander <blackslayer4@gmail.com>
2021-07-01 11:59:20 +03:00
Felix Weilbach c9715db720 Check if first is not empty
If it's not checked that first is empty, crashes may happen.

Signed-off-by: Felix Weilbach <felix.weilbach@nextcloud.com>
2021-06-30 06:57:41 +00:00
Felix Weilbach 2ee3ca02a4 Add unit test for move custom remote root
Signed-off-by: Felix Weilbach <felix.weilbach@nextcloud.com>
2021-06-25 10:14:29 +00:00
allexzander a3d12a616b Add error message to GUI.
Signed-off-by: allexzander <blackslayer4@gmail.com>
2021-06-15 14:33:45 +03:00
allexzander 6312f6ddde Wipe empty folder when moving a VFS placeholder. Keep a folder if there are hydrated items inside.
Signed-off-by: allexzander <blackslayer4@gmail.com>
2021-06-15 13:19:35 +03:00
allexzander bb55232e8e VFS freeze fix. Treat .sync-exclude.lst as a non-virtual file always.
Signed-off-by: allexzander <blackslayer4@gmail.com>
2021-06-08 09:25:43 +00:00
Felix Weilbach 78f1943d76 Add a key value store to the sync journal
This key value store should help to keep track of important events,
that can not be store in the logs, because the logs are deleted too fast.

Signed-off-by: Felix Weilbach <felix.weilbach@nextcloud.com>
2021-05-19 09:04:43 +02:00
allexzander 76be5dce73 Add remote folder prefix for renaming in a non-root local folder.
Signed-off-by: allexzander <blackslayer4@gmail.com>
2021-05-17 12:19:58 +00:00
Hannah von Reth e04c6abcd5 Fix placeholder detection for cfapi
Fixes: #8326
Signed-off-by: Matthieu Gallien <matthieu_gallien@yahoo.fr>
2021-05-06 07:35:59 +00:00
Felix Weilbach 696979cb0e Display invalid filenames as warning
Signed-off-by: Felix Weilbach <felix.weilbach@nextcloud.com>
2021-04-13 14:58:51 +00:00
allexzander 4b58c2b7b7 Fix review comments.
Signed-off-by: allexzander <blackslayer4@gmail.com>
2021-04-07 09:08:02 +00:00
allexzander de85b79bb8 Address review comments.
Signed-off-by: allexzander <blackslayer4@gmail.com>
2021-04-07 09:08:02 +00:00
allexzander cb8b6ccd9b Ignore *.lnk files on Windows.
Signed-off-by: allexzander <blackslayer4@gmail.com>
2021-04-07 09:08:02 +00:00
allexzander 13f4bb541d Treat .lnk files as normal files without hydrating them or creating a placeholder.
Signed-off-by: allexzander <blackslayer4@gmail.com>
2021-04-07 09:08:02 +00:00
allexzander 3906ae0922 Another way to fix this.
Signed-off-by: allexzander <blackslayer4@gmail.com>
2021-04-07 09:08:02 +00:00
allexzander 7235c708dc Added .lnk file placeholder creation fix.
Signed-off-by: allexzander <blackslayer4@gmail.com>
2021-04-07 09:08:02 +00:00
allexzander d5b6d93978 Fix VFS freeze when syncing '.lnk' files on Windows.
Signed-off-by: allexzander <blackslayer4@gmail.com>
2021-04-07 09:08:02 +00:00
Felix Weilbach b1983d7d19 Increase logging around file removal events
To better see what is going on when and if files are removed by the
client.

See also: #260, #1433, #2913

Signed-off-by: Felix Weilbach <felix.weilbach@nextcloud.com>
2021-03-22 07:48:39 +00:00
allexzander 4d66d209bc Fix incorrect logger output for non-latin strings.
Signed-off-by: allexzander <blackslayer4@gmail.com>
2021-02-16 09:30:08 +02:00
Kevin Ottens dd83efb543 The e2eMangledName was relative to the remote folder, repair it
This got broken during the huge discovery refactoring. I wrongly passed
the mangled name as is out of discovery, but coming from listing jobs it
was fully qualified while the jobs at propagation time and the db expect
those paths to be relative to the remote folder.

Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
2021-02-04 11:16:48 +00:00
allexzander eb80f54dcf E2EE Fix incorrect name of a nested encrypted item in the Settings dialog when the root folder is non-encrypted and it is renamed.
Signed-off-by: allexzander <blackslayer4@gmail.com>
2021-01-25 10:35:54 +02:00
allexzander 79fe231acc Fix E2EE root folder rename issue.
Signed-off-by: allexzander <blackslayer4@gmail.com>
2021-01-25 10:35:30 +02:00
allexzander 96472320e4 Fix e2ee folder move issue
Signed-off-by: allexzander <blackslayer4@gmail.com>
2021-01-14 15:54:30 +02:00
Kevin Ottens 216b251b40
One byte placeholders assumption only holds for the suffix backend
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
2020-12-30 09:44:57 +01:00
rakekniven e1979fdb33 Removed translation for "etag" and changed spelling
Shouldn't be translated.

Just checked https://en.wikipedia.org/wiki/HTTP_ETag and all available localized pages.

Signed-off-by: rakekniven <mark.ziegler@rakekniven.de>
2020-12-28 08:51:56 +00:00
Kevin Ottens af57a702ef
Workaround bug in older GCC used for the AppImage toolchain
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
2020-12-15 11:01:53 +01:00
Kevin Ottens c57eff6fd8
Please the clang-tidy overlord
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
2020-12-15 11:01:53 +01:00
Hannah von Reth ebd8047cb6
Replace custome date parser QDateTime::fromString(value, Qt::RFC2822Date) 2020-12-15 11:01:52 +01:00
Kevin Ottens 567f678fd5
Make sure the encrypted flag gets all the way to the journal db
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
2020-12-15 10:59:21 +01:00
Kevin Ottens 1d07af07a5
Start hooking up E2EE to the new discovery algorithm
Now we pull the encrypted metadata during the discovery which is a
better approach than before. This shall remove the need for some of the
deep propfinds we have been using so far. It already simplifies the code
a bit for the download scenario.

Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
2020-12-15 10:59:21 +01:00
Hannah von Reth 0eabc75039
Improve log message 2020-12-15 10:59:18 +01:00
Hannah von Reth 47dc7e6c49
Remove custome string functions 2020-12-15 10:59:15 +01:00
Hannah von Reth 8cbdb4451b
Remove now unneede csync_instruction_str 2020-12-15 10:59:10 +01:00
Olivier Goffart 0e7c56e81c
Don't show the "All files deleted" popup when unselecting everything with selective sync
Issue #7337
2020-12-15 10:59:04 +01:00
Olivier Goffart 392d3c257c
Discovery: Allow more HTTP error code to be treated as ignored dir
The original code from csync was stopping at any error.
But we have been whitelisting soeme http error code one by one
to ignore the directory instead of aborting the sync.
However, as there are more requests to continue the sync in case
of error, just ignore most HTTP errors

Issue #7586
2020-12-15 10:59:03 +01:00
Olivier Goffart fc0aeb53b1
Discovery: fix TestSyncVirtualFiles::testExtraFilesLocalDehydrated on windows
On windows we do a test to know if we should change the case of the files,
but that conflict with the test that checks if the file was still there
when the filename is actually the same. Which can happen with virtual files
as they have two representation (the one with and without suffix).
2020-12-15 10:59:02 +01:00
Christian Kamm 4c4cbf0d97
Vfs: Lots of tests and corrections for suffix edge cases
Avoid or deal with problems that happen when suffixed files exist on the
server or suffix and non-suffixed files exist locally.

See #7350, #7261.
2020-12-15 10:59:02 +01:00
Olivier Goffart 88f86a56b1
Discovery: Attempt to fix issue with windows VFS and new files
(or moved files)
As seen in the log of #7558, a conflict may be issued by mistake.

See investigation in https://github.com/owncloud/client/issues/7558#issuecomment-547385362

This hopefully fix #7558
2020-12-15 10:59:02 +01:00
Olivier Goffart 83d743b66b
When moving is allowed but deleting is not, do not restore moved items
Issue #7293
2020-12-15 10:59:01 +01:00
Olivier Goffart adbd3d869b
Fix warning about serverJob not being used
And fix a FIXME in the same time
2020-12-15 10:59:00 +01:00
Christian Kamm e91e1ca78f
Test: Disable local discovery parallelism in permission test
Adding parallelism broke the test because it depended on the order of
discovery.
2020-12-15 10:59:00 +01:00
Christian Kamm 71f71b38f1
Discovery: local job shouldn't be parented
Since it'll be deleted by the thread pool.
2020-12-15 10:58:59 +01:00
Christian Kamm 53a217d4e4
Don't store pointer to local job
There were crashes in the QPointer assignment. Possibly the thread pool
is done with the job and deletes it before the assignment is done.
2020-12-15 10:58:59 +01:00