Commit graph

419 commits

Author SHA1 Message Date
Olivier Goffart
e69ecd3a80 hbf: add a callback when the chunk upload is finished
Also add an user_data to other callbacks
2013-10-16 16:46:50 +02:00
Olivier Goffart
f9ce534687 Merge branch 'dav' into ocsync
Conflicts:
	src/csync.c
2013-10-15 16:55:22 +02:00
Olivier Goffart
6601395a6e Do not overwrite the neon error string with the HTTP error
When the errno is ERRNO_ERROR_STRING it means the error string is a
valid string with the error, and it should not be overwritten with
the HTTP reason_phrase

Fixes https://github.com/owncloud/mirall/issues/1088
2013-10-15 14:02:17 +02:00
Klaas Freitag
a7d298a441 Fix c99 warning. 2013-10-07 12:59:35 +02:00
Markus Goetz
617949f2e1 Recursive PROPFIND: Change and improve
It is disabled by default, but can be enabled by the library
user on demand. We suggest to enable it for the first sync
and when the local DB is small enough.
It only gets used for the first PROPFIND. In case the server
supports the Depth 'infinity', we keep the cache. In case
the server does not support it (= reports only 1 level)
we will still use the result by converting it to the legacy
PROPFIND cache.
2013-10-04 13:23:10 +02:00
Klaas Freitag
8d14286bd3 Merge dav and transmit the mtime with the PUT request 2013-09-25 14:23:04 +02:00
Klaas Freitag
373746c296 Fix crash in case of NE_TIMEOUT happened.
Fixes https://github.com/owncloud/mirall/issues/1010

In case of NE_TIMEOUT the request is repeated for three times. In this
case, the hooks weren't correctly unhooked which caused a crash.
2013-09-18 12:58:17 +02:00
Klaas Freitag
525278450a Fix crash in case of NE_TIMEOUT happened.
Fixes https://github.com/owncloud/mirall/issues/1010

In case of NE_TIMEOUT the request is repeated for three times. In this
case, the hooks weren't correctly unhooked which caused a crash.
2013-09-18 12:57:15 +02:00
Klaas Freitag
de074804eb Detect empty etags coming from server side. 2013-09-16 16:15:15 +02:00
Olivier Goffart
79c1514a2b Chenge the headers to LGPL for the file that were added in the dav branch
The LGPL changes was not merged for the new files
2013-08-21 13:23:52 +02:00
Olivier Goffart
56d5359f5b Fix compilation after merge
Still untetested
2013-08-18 18:55:32 +02:00
Olivier Goffart
b5ed352aa3 Merge remote-tracking branch 'origin/master' into ocsync
Only confluct resolution, do not compile or works

Conflicts:
	CMakeLists.txt
	CPackConfig.cmake
	ConfigureChecks.cmake
	client/csync_client.c
	cmake/Modules/DefineCompilerFlags.cmake
	cmake/Modules/DefineInstallationPaths.cmake
	cmake/Modules/FindIconv.cmake
	cmake/Modules/FindIniparser.cmake
	cmake/Modules/FindNeon.cmake
	config.h.cmake
	config/CMakeLists.txt
	config/ocsync.conf
	doc/CMakeLists.txt
	modules/csync_owncloud.c
	modules/csync_sftp2.c
	src/CMakeLists.txt
	src/csync.c
	src/csync.h
	src/csync_config.c
	src/csync_exclude.c
	src/csync_lock.c
	src/csync_macros.h
	src/csync_misc.c
	src/csync_misc.h
	src/csync_private.h
	src/csync_propagate.c
	src/csync_statedb.c
	src/csync_statedb.h
	src/csync_update.c
	src/csync_util.c
	src/csync_util.h
	src/std/c_dir.c
	src/std/c_file.c
	src/std/c_private.h
	src/std/c_string.c
	src/std/c_string.h
	src/std/c_time.c
	src/vio/csync_vio.c
	src/vio/csync_vio.h
	src/vio/csync_vio_file_stat.h
	src/vio/csync_vio_local.c
	src/vio/csync_vio_method.h
	tests/CMakeLists.txt
	tests/csync_tests/check_csync_statedb_load.c
	tests/csync_tests/check_csync_statedb_query.c
	tests/csync_tests/check_csync_treewalk.c
	tests/csync_tests/check_csync_update.c
	tests/ownCloud/HTTP/DAV.pm
	tests/ownCloud/ownCloud/Test.pm
	tests/std_tests/check_std_c_str.c
	tests/vio_tests/check_vio.c
2013-08-18 16:21:18 +02:00
Krzesimir Nowak
3979d002bd Add an owncloud-specific redirect callback. 2013-08-05 19:21:38 +02:00
Olivier Goffart
6766f41bf5 Add a hook in httpbf to do the logging 2013-08-01 13:13:05 +02:00
Klaas Freitag
38403f3343 Fix compile warning. 2013-08-01 09:59:48 +02:00
Klaas Freitag
0524613a57 Removed end up- and download notification, done in propagate. 2013-08-01 09:30:13 +02:00
Klaas Freitag
344ea661c9 Add more logging to chunking routines. 2013-07-31 16:26:28 +02:00
Daniel Molkentin
d9b34121ae Fix OS X build with -Werror 2013-07-31 14:50:44 +02:00
Daniel Molkentin
8d99364d63 Eliminate all warnings
- use proper casts
- use aproproate types
- offer to build with -Werror
- make printf attribute hinting gnu format style
- remove unused helper methods
- begin to use inttyes.h macros where suitable
- move var declarations to the beginning of the method
- properly use _FILE_OFFSET_BITS
- silence variables unused depending on the define
2013-07-31 13:12:10 +02:00
Olivier Goffart
4f5bfbdb78 Use int64_t instead of off_t
off_t is 64 or 32 bit depending on the architecture and the defines for
large file support.  It is better to always use int64_t which is always
64 bits
2013-07-30 16:33:19 +02:00
Andreas Schneider
5e0cd2276c owncloud: Fix #ifdef mess. 2013-07-30 09:50:14 +02:00
Klaas Freitag
6ef2b25bff owncloud: Fix compile warnings if NDEBUG is not defined.
Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
2013-07-30 09:23:22 +02:00
Klaas Freitag
2fcfe883eb Proper error reporting for HBF PUT fails. 2013-07-30 08:56:53 +02:00
Klaas Freitag
d53a3f2f98 Only log when really something was transmitted. 2013-07-29 15:27:22 +02:00
Klaas Freitag
1e1df5d94d ownCloud: Add a log entry when chunk is uploaded. 2013-07-29 14:27:01 +02:00
Andreas Schneider
d80da2a088 LICENSE: Change license of libcsync from GPL to LGPL.
All contributors have agreed to change the license of libcsync to LGPL.
2013-07-29 14:04:37 +02:00
Klaas Freitag
2cc5bbe187 ownCloud: Some fixes to promote the correct progress. 2013-07-26 13:43:02 +02:00
Klaas Freitag
0a15f0e7ad New progress API: Consolidate to one progress Callback having all info.
Before there were two callbacks, one for the individual file and one for
for the overall progress. Now its more easy and clean.
2013-07-25 15:36:46 +02:00
Andreas Schneider
d454a261ce owncloud: Fix a build warning. 2013-07-25 08:39:46 +02:00
Olivier Goffart
3d1994747a Also allow to specify a % of bandwidth for the limit 2013-07-24 18:17:59 +02:00
Olivier Goffart
6109b22aa6 Implement bandwidth limitation 2013-07-24 18:17:54 +02:00
Klaas Freitag
03685bd15b owncloud: Fix compile warnings if NDEBUG is not defined.
Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
2013-07-24 16:34:51 +02:00
Klaas Freitag
9c09c1f1cb owncloud: Removed malicious logging.
Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
2013-07-24 16:33:19 +02:00
Olivier Goffart
09e30509d1 Propertly report the error from the server while uploading 2013-07-23 17:40:44 +02:00
Olivier Goffart
75682f981d Add a threshold to httpbf before splitting the files 2013-07-23 17:31:31 +02:00
Klaas Freitag
4f45381920 owncloud: Also pass user from commandline.
Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
2013-07-23 07:39:14 +02:00
Klaas Freitag
939b262766 smb: Handle username given on command line correctly.
Only ask for password if username is specified.

BUG: https://open.cryptomilk.org/issues/13

Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
2013-07-23 07:36:43 +02:00
Klaas Freitag
9d1e020970 owncloud: Use correct namespace for fixing modification times.
Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
2013-07-23 07:32:22 +02:00
Klaas Freitag
35ebf70ad1 owncloud: Clear the stat cache on close to force a new stat call.
Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
2013-07-23 07:31:40 +02:00
Klaas Freitag
40d1498fc3 owncloud: Fix possible NULL pointer dereferences.
CID: #996808

Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
2013-07-22 15:46:54 +02:00
Klaas Freitag
f552637ffd owncloud: Fix a possible null pointer dereference.
CID: #996827

Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
2013-07-22 15:38:55 +02:00
Klaas Freitag
45cdcb7502 Add a progress callback for overall and individual file up and download
progress.
2013-07-19 12:26:48 +02:00
Markus Goetz
1263ca990d Fix download resuming on OS X 2013-07-16 13:33:55 +02:00
Klaas Freitag
9046df8985 CID 1032811: Fix resource leaks on error.
Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
2013-07-12 12:09:49 +02:00
Klaas Freitag
4c1106066a CID 1032813: Add missing break statement.
Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
2013-07-12 12:09:01 +02:00
Klaas Freitag
be58f3a64e CID 1032816: Leave the ownership of the buffer to the calling function.
Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
2013-07-12 12:06:30 +02:00
Andreas Schneider
9382a047ae cmake: Update FindNeon and add support for version checking. 2013-07-12 11:57:07 +02:00
Klaas Freitag
ebc98f07c3 Cleaned code a bit, covertiy found. 2013-07-12 11:41:51 +02:00
Olivier Goffart
c20a2bf16b Add a way to configure the block size for httpbf 2013-07-10 12:15:11 +02:00
Klaas Freitag
2befdf50da Fix coverity CID 1029796 2013-07-08 12:26:44 +02:00