Commit Graph
100 Commits
Author SHA1 Message Date
Olivier Goffart 441b5bd1dc Setup Wizard: remove all folder definition before starting a new sync
Issue #1989
2014-12-04 15:18:27 +01:00
Olivier Goffart a23e0fef8d Update binary submodule 2014-12-03 11:18:01 +01:00
Olivier Goffart 0fd0b08c09 Windows shell integration: Always release the lock before calling win32 API
May help for 2515
2014-12-03 09:11:38 +01:00
Olivier Goffart 8fbb55a0c8 Wizard: Fix escaping of error message.
An url can contains % signs, so if it does, the errors formating was wrong
because of the use of QString::args

Also, the error is in html format, and we need to let the message box know
that, otherwise we will just see <br/>
2014-12-02 10:22:46 +01:00
Olivier Goffart f046a7e7fe Wizard: Attempts to really close the database when starting the backup
Still for issue #1989
2014-12-02 10:22:46 +01:00
Olivier Goffart b154e1baa1 Nautilus shell integration: Use fallback when XDG_RUNTIME_DIR is not defined
Same fallback as in Qt5

Task #2477
2014-12-01 12:06:09 +01:00
Olivier Goffart 2ed2ef3b28 Propagator QNAM: Fix resuming
We forgot to account the fact that we could have been resuming when
comparing the size of the Content-lenght to the size of the temporary file
2014-11-27 14:50:49 +01:00
Olivier Goffart e7e91b6931 Revert "Folder: Don't blindly trigger sync on first EtagJob result"
We need to do a sync even if the etag was empty because we do not know
if this is because the etag really changed or because it was new.

Also, some part of the code rely on this fact to schedule a sync.

The fact that there is two sync with 30 sec at the beginning is not
a big problem, because we also need to do the sync the put the directory
etag in the db.

This reverts commit 1c001ee138.
2014-11-27 12:50:36 +01:00
Olivier Goffart 1f9d02e7fa Shibboleth: Fix our implemtnation of CookieJar::deleteCookie
It was deleting too many cookies.
That function is virtual in Qt5 and is used when adding cookie.
But some Shibboleth have several cookies with the same name, and we need to keep them.

Our implementaiton was meant to delete all the shiboleth cookies when we want to log out
2014-11-27 12:26:59 +01:00
Olivier Goffart 41568c885d Propagator: only check the content-lenght if it is there
If content-lenght is 0, don't chack it is the size we recieved.
It can be zero when using HTTP chunk encoding.

Also do not remove the temporary file so it can be re-used on the next sync
and ask for a new sync immediatly to re-do the sync.

Fixup the fix to task #2528
2014-11-21 11:03:14 +01:00
Olivier Goffart b04cb23ed5 t8.pl: fix the test for me
On localhost, the other file (the bigger one) was downloaded first
2014-11-11 16:38:20 +01:00
Olivier Goffart b70ecc3dd3 Never overwrite the mtime from the local file system in the db when updating the metadata
Attempt to fix #2431
2014-11-06 15:13:10 +01:00
Olivier Goffart 1eccfb798f Add missing license headers
Part of #2068
2014-10-29 13:30:46 +01:00
Olivier Goffart 7810da51a8 Propagator: report error when deleting directories
Will help to understand why a directory cannot be removed

Will help for #2348
2014-10-29 12:23:48 +01:00
Olivier Goffart a470138450 Windows Shell Integration: refresh the cache on UPDATE_VIEW
Attempt to fix #2383
2014-10-29 11:00:51 +01:00
Olivier Goffart 5723abe6eb Merge remote-tracking branch 'origin/fix_service_unavailable' into 1.7 2014-10-27 20:49:46 +01:00
Olivier Goffart ce300d88ee Wizard: show the choice to start a clean sync if the directory exist even on new accounts
Task #2406
2014-10-27 13:05:17 +01:00
Olivier Goffart cddad94e45 Selective Sync: change the label text
to specify that the files will be removed from the local folder

Task #2404
2014-10-27 11:33:25 +01:00
Olivier Goffart de56b753d1 protocolwidget: fix string that need to use plural translation 2014-10-22 18:26:40 +02:00
Olivier Goffart dab01e3f3f csync_update: add the perms in the log 2014-10-22 17:25:38 +02:00
Olivier Goffart e46ab72718 SocketAPI: Show error when we are not allowed
Issue #1931
2014-10-22 17:25:38 +02:00
Olivier Goffart 9330d2e1e8 SocketAPI: always clean the path and use the normal slash 2014-10-22 15:33:35 +02:00
Olivier Goffart 020e19f770 SocketAPI: Fix all files are new
(Introduced because of bad resolution of merge conflict
in my last commit)
2014-10-22 15:32:09 +02:00
Olivier Goffart 3be5600caf t6.pl: fix missing space in curl command 2014-10-22 15:16:22 +02:00
Olivier Goffart 22dd275b15 SocketAPI: Fix the shared symbol, including for owncloud6 Shared dir
The shared symbol would not appear if the status came for estimateState

Also added the shared symbol for the Shared/ directories (owncloud 6 compat)
2014-10-22 15:10:21 +02:00
Olivier Goffart dd45b448d9 t6.pl: pass the --insecure flag to curl so it works on the test machine 2014-10-22 13:57:22 +02:00
Olivier Goffart 7740150576 Selective Sync widget: add a "Loading..." label
Task #2088
2014-10-22 13:48:05 +02:00
Olivier Goffart 4f367faf4d SocketAPI: Show an error for files inside the selective sync folders
Task #2283
2014-10-22 13:31:20 +02:00
Olivier Goffart 3840186dd8 Utility: fix function signature 2014-10-22 13:31:20 +02:00
Olivier Goffart 6073e3f345 SocketAPI: do not show a progress icon in case of errors 2014-10-22 12:19:57 +02:00
Olivier Goffart d31ccacf57 SocketAPI: show an ignored icon for paused folders 2014-10-22 12:19:57 +02:00
Olivier Goffart a76fc0ee5a SocketAPI: send the change of the parent folder in the broatcast
Also do not compute the status if there is nno listeners
2014-10-21 15:26:51 +02:00
Olivier Goffart 80e86d6c1b ownsql: fix warning with clang
warning: equality comparison with extraneous parentheses [-Wparentheses-equality]
2014-10-21 14:59:42 +02:00
Olivier Goffart dc13e39bb1 SocketAPI: do not have a special case for UPDATE_VIEW on windows
This is a relique on the old times when there was no persistant connection
in the windows plugin
2014-10-21 14:57:50 +02:00
Olivier Goffart 98c5871d38 Windows shell integration: Add SHCNF_FLUSHNOWAIT to SHChangeNotify
(TortoiseSVN have this flag)

Also do not call SHChangeNotify if there was no change
2014-10-21 14:51:18 +02:00
Olivier Goffart 5a109d9293 Fix t3.pl
The fix in commit 86d8079 made the detection of changes inside
a directory more robust.
As a result, changes are detected inside a directory, even if the
files that are changed were moved away on the other remote, the algorithm
won't let the directory be removed and the directory will be re-created
2014-10-21 12:10:12 +02:00
Olivier Goffart 56316bc980 csync_reconcile: remove useless debug output 2014-10-21 11:47:18 +02:00
Olivier Goffart 86d8079739 Reconcile: Make sure not to loose new files added in a directory removed on the server
Found while investigating #2296

The problem is that we should not remove a directory locally if it contains
modified files.
But the modification time of the directory is not necessarily chaning (so
the instruction of the directory may still be NONE)

We have to move the child_modified test a bit down to be recursive
2014-10-21 10:38:21 +02:00
Olivier Goffart a5bd437d48 Propagator: Fix renaming of files and case confflicts
Better fix for #1385 and #2318
2014-10-17 16:15:03 +02:00
Olivier Goffart 08156186fa Revert "propagator: Do not check for case clash when renaming"
This caused test regressions in t8.pl (#2318)

This reverts commit dad8c1c27c.
2014-10-17 16:15:03 +02:00
Olivier Goffart 2bba4134fb owncloudgui: Fix a small leak
The systray icon were not destroyed while qutting
2014-10-15 18:11:52 +02:00
Olivier GoffartandDaniel Molkentin 7804bf0a9a Windows Shell Integration: Use the right parametter to SHChangeNotify 2014-10-15 16:47:08 +02:00
Olivier GoffartandDaniel Molkentin bb37e93f52 Windows shell integration: Do proper wait 2014-10-15 16:09:35 +02:00
Olivier GoffartandDaniel Molkentin aa0f2c64ff Windows Shell Integration: fixeWindows Shell Integration: fixe 2014-10-15 15:57:15 +02:00
Olivier Goffart e66ca267f4 Windows Shell Integration: try to wait for connection 2014-10-15 15:13:04 +02:00
Olivier Goffart 4b001a77b3 Windows Shell Integration: Use the QLocalSocket on windo and do the request assynchroniously
Squashed commit of the following:

commit 4d9b072f560fa171a1390b7c74425614aa20e955
Author: Olivier Goffart <ogoffart@woboq.com>
Date:   Tue Oct 14 16:04:02 2014 +0200

    Remove useless variable

commit 8e85de0307ec5f31bf3f92a7de793fed7d41c2ea
Author: Daniel Molkentin <danimo@owncloud.com>
Date:   Tue Oct 14 16:01:52 2014 +0200

    Make Windows Explorer Extension build

commit 8e2942cd9fd32e3af72d60cba0d06bd9d6222a45
Author: Daniel Molkentin <danimo@owncloud.com>
Date:   Tue Oct 14 11:39:37 2014 +0200

    Fix compilation

commit 0fc0c0e0e0c7e58ad97f62700256c7d1f8c0670b
Author: Olivier Goffart <ogoffart@woboq.com>
Date:   Tue Oct 14 11:48:32 2014 +0200

    Windows Shell Integration: Try to let the thread notify about changes when there are changes

commit 4a1712b7c03269ca3007f167b8f313ea47655967
Author: Olivier Goffart <ogoffart@woboq.com>
Date:   Tue Oct 14 11:35:20 2014 +0200

    Windows Shell Integration: Share the RemotePathChecker amongst all the OCOverlay instances

commit 2d87408e9af5a4d7ab71c460ce606ba1f367c09f
Author: Olivier Goffart <ogoffart@woboq.com>
Date:   Mon Oct 13 18:55:15 2014 +0200

    Windows Shell Integration: Attempts to wait on multiple objects (WIP)

commit e448e427b6d1561ad7a40d08fc6632f4d2b4ef44
Author: Daniel Molkentin <danimo@owncloud.com>
Date:   Mon Oct 13 17:58:02 2014 +0200

    Introduce a worker thread

commit 2344407ec0bc1ce173ebbacadcf3992d62d94078
Author: Olivier Goffart <ogoffart@woboq.com>
Date:   Mon Oct 13 17:03:47 2014 +0200

    Windows Shell Integration:  try to keep the socket open using a thread (WIP)

commit ea6d5273ed60d8bc3f1c5d5c6936364d783a1c0f
Author: Daniel Molkentin <danimo@owncloud.com>
Date:   Mon Oct 13 15:27:46 2014 +0200

    Make Explorer plugin work again with named pipes

    This is a temporary hack, which needs more refactoring.

commit 44a3437a44082379efa0078c9afd7b8bbde930de
Author: Daniel Molkentin <danimo@owncloud.com>
Date:   Sat Oct 11 07:31:24 2014 +0200

    Fix code

commit 123390a0f3516c0078309d7048c6d2acb9293676
Author: Olivier Goffart <ogoffart@woboq.com>
Date:   Fri Oct 10 16:29:35 2014 +0200

    Windows shell integration: Use named pipe  (WIP)

commit 9eea7e2321abeac6b8db0bd85bfce612dbf6bb20
Author: Olivier Goffart <ogoffart@woboq.com>
Date:   Wed Oct 1 12:04:13 2014 +0200

    Windows Shell Integration: Simplify StringUtil

    This fixes a memory leak in CommunicationSocket::ReadLine
2014-10-14 16:05:48 +02:00
Olivier Goffart 7e898cf60c SelectiveSync: rename blacklist to selectiveSyncBlackList in some places
Issue #2301
2014-10-11 16:24:45 +02:00
Olivier Goffart 282abdd804 Sync engine: Restart sync when we get a precondition failed error 2014-10-11 15:40:28 +02:00
Olivier Goffart 9b178c5bb2 Sync engine: Do not write to the database too early
It is possible that we have should_update_etag set to true for files
that we also need to propagate.  In which case we must not write to the DB
too early as this could cause data loss.  (cf: issue #2296)
2014-10-11 15:40:28 +02:00
Olivier Goffart 100d1361b6 Add Folder wizard: Sort the folders when selecting the remote folder
Issue #1872
2014-10-10 16:56:05 +02:00
Olivier Goffart d880f2ffbc propagator: Do not show an error message saying it was done by user interaction if it was not
There is many reasons why we could abort (for example timeouts)
And in this case we should not show to the user it was aborted
by user interaction
2014-10-10 14:58:56 +02:00
Olivier Goffart 661fe5df66 csync_statedb: fix inverted logic in testing if the sqlite was compiled with threads 2014-10-10 10:12:54 +02:00
Olivier Goffart b20752f13e Fix the build with clang and Qt4 2014-10-09 17:54:46 +02:00
Olivier Goffart 4c83653d5d Selective sync: do not upload or rename file that would ends up in a not selected folder
Issue #2283
2014-10-09 16:50:03 +02:00
Olivier Goffart 621a37be15 Selective sync: Remove the etag of parent folders in the db when adding or removing items in the selective sync blacklist 2014-10-09 15:28:51 +02:00
Olivier Goffart 6de104a03a Selective Sync: ensure that the blacklist contains the last '/'
In the sync engine.  Because that makes tha tthe lower_bounds in selective sync works properly.

For example, if both "Test" and "Test Test" are in the list,  then "Test/Foo" would match the "Test Test"
 because slash is after space

Task #2289
2014-10-09 15:11:04 +02:00
Olivier Goffart 97560509ea Selective sync: change the text of the label.
Selective sync is a black list.  Unchecked folder are blacklisted
Partially checked folders are not in the blacklist and the files there
are sync'ed
2014-10-09 14:36:26 +02:00
Olivier Goffart 0d303f1d1f SelectiveSync: sort the item instead of using the order from the server
Task #2259
2014-10-01 13:47:24 +02:00
Olivier Goffart 147fa60f81 Merge branch 'socketapi_localsocket' into 1.7 2014-10-01 12:34:22 +02:00
Olivier Goffart a1b9405e2e Windows has not been ported back to QLocalSocket 2014-10-01 12:33:54 +02:00
Olivier Goffart db02d44c6a No need to update mtime and etag after a move
The server keeps the mtime and etag anyway.
And changing the mtime also changes the etag and so make other clients re-download
the file instead of detecting the move
2014-10-01 11:22:00 +02:00
Olivier Goffart a587148c73 SocketApi: Save the socket in $XDG_RUNTIME/<appname>/socket 2014-09-29 13:54:13 +02:00
Olivier Goffart 9acd3a58ee SocketApi: Use QLocalSocket after all for windows and linux
Relates issue #2189
2014-09-29 12:19:33 +02:00
Olivier Goffart 10989d13e4 Folder: Remove slotTerminateAndPauseSync
This make no sens to just set the pause config flag here. It make selective sync to mark
the folder as posed on restart
2014-09-26 12:43:54 +02:00
Olivier Goffart fe1653ede6 csync_update: don't recurse into ignored directory.
This save some time when selective sync deselected a large tree
2014-09-26 12:35:56 +02:00
Olivier Goffart b4071cec01 DiscoveryPhase: fix the name of a function
It was renamed from white list to black list long ago
2014-09-26 12:35:56 +02:00
Olivier Goffart a3d70b3cf6 Attempt to fix a crash
The reply might be null at the point we are timing out.
Issue #2246
2014-09-26 10:04:36 +02:00
Olivier Goffart dad8c1c27c propagator: Do not check for case clash when renaming
Issue #1385

When renaming, we would normaly already have an error if the file already exist.
And we want to allow the renaming to chang ethe case (Eg. "hello" -> "HELLO"
2014-09-24 16:43:01 +02:00
Olivier Goffart 292a7357bd t1.cfg.in: saner placeholder executable name
Now it is owncloudcmd and not csync
2014-09-17 14:39:34 +02:00
Olivier Goffart 9b1779bb06 Fix compilation
qFatal does not work with <<
2014-09-15 18:03:44 +02:00
Olivier Goffart 97cc05eeea journaldb: Assert in case of SQL error
relates issue #2106
2014-09-15 14:27:39 +02:00
Olivier Goffart 5870a57002 wizard: fix start a clean sync
The problem was that the backup function failed as we tried to
move  /home/xxx/ownCloud/  to /home/xxx/ownCloud/.oC_bak
The intention was to move it to /home/xxx/ownCloud.oC_bak

Issue #1989
2014-09-15 13:49:13 +02:00
Olivier Goffart 278bc5a8cd owncloudcmd: ask for the login and password and put it in the url (if it's not there already)
Because we cannot rely on HTTPCredentials to open windows in a command line tool

Fixes #1860
2014-09-15 13:24:31 +02:00
Olivier Goffart af5e8ee18c AbstractNetworkJob
Abort the transfer in case of timeout.

This avoid that a connection that never replies blocks mirall

Issue #2148
2014-09-12 18:06:29 +02:00
Olivier Goffart 52e8343f76 ConnecitonValidator: Handle the timeout
otherwise the account may be stuck in a disconnect case if there is a timeout

Issue #2148
2014-09-12 18:06:17 +02:00
Olivier Goffart a4dbf5942c owncloudcmd: restart the sync if required
Fixes #2038
2014-09-12 17:23:01 +02:00
Olivier Goffart 79052ba7c6 Blacklist: ignore problems that don't have HTTP error code and are possibly problem on the local file system
Issue #1985
2014-09-12 14:13:04 +02:00
Olivier Goffart a84b7dc27e Restart the sync when we detect we need to redo a sync
Fixes #1968
Relates #2038
2014-09-10 17:27:33 +02:00
Olivier GoffartandDaniel Molkentin 79ee6c2f3b csync_vio_local on windows: fix overflow when computing the size of file > 4GiB
MAXDWORD is 0xFFFFFFFF, so if we add one, it overflows and is 0.
We need to cast it to 64 bits before
2014-09-10 13:21:31 +02:00
Olivier Goffart fa962b7f53 csync_update: fix compilation warning 2014-09-10 11:08:00 +02:00
Olivier Goffart 71408bab60 I forgot to rename one of the while list to the blacklist 2014-09-10 11:01:38 +02:00
Olivier Goffart 291231c561 Merge missing commits from 1.6.2-themefix into 1.7
Conflicts:
	VERSION.cmake
2014-08-30 17:57:58 +02:00
Olivier Goffart 5d19426930 Propagator: When the server don't support ranges, reset the counter so the progress is not messed up
Issue #2081
2014-08-29 19:33:20 +02:00
Olivier Goffart 1b51a10b19 Socket API: be consistant in the VERSION command and add the VERSION at the beginning 2014-08-29 17:28:36 +02:00
Olivier Goffart aab870af32 desktop file: add a Comment
Fixes #2130
2014-08-29 17:14:40 +02:00
Olivier Goffart 34a27c748a Progress: in case of resuming chunks, advance directly at startup by the amount of chunk already done
Fixes #2103
2014-08-29 16:06:56 +02:00
Olivier Goffart a73fbccf8c t4.pl: add a test to test that ignored file are not deleted 2014-08-28 19:33:52 +02:00
Olivier Goffart d4bbd28757 csync: remove ignored_cleanup: it's not used anymore 2014-08-28 17:16:51 +02:00
Olivier Goffart 98b7248df0 reconcile/update: don't remove directory that contains ignored files 2014-08-28 17:16:17 +02:00
Olivier Goffart 0fb0f2c204 Selective sync: start a sync when the selective sync settings changes 2014-08-28 16:27:46 +02:00
Olivier Goffart 79d13d9242 Selective sync: deselecting a folder removes it from the local file system 2014-08-28 15:53:49 +02:00
Olivier Goffart 79f00c2a2a Wizard: adjust alignements 2014-08-28 13:32:14 +02:00
Olivier Goffart e5068e7543 Selective sync: if one click twice on the button in the wizard, it should keep the blacklist 2014-08-28 12:25:44 +02:00
Olivier Goffart 858218ac34 Wizard: new layout 2014-08-28 12:18:19 +02:00
Olivier Goffart a73316306d Selective sync: new design in the wizard 2014-08-27 19:03:11 +02:00
Olivier Goffart 928652e4cf Selective sync: rename the button 'choose what to sync' 2014-08-27 17:31:57 +02:00
Olivier Goffart 7950b49cb1 Selective sync dialog: fix fetching sub directory when the folder is not the root folder 2014-08-27 17:19:36 +02:00
Olivier Goffart ea381392a7 SocketAPI: fix the BROADCAST message 2014-08-27 13:55:06 +02:00
Olivier Goffart bb7f63dcfd AccountSettings: be less verbose in the status string 2014-08-27 13:51:14 +02:00
Olivier Goffart 253d65727b Socket api: Add a VERSION command 2014-08-27 13:51:14 +02:00