mirror of
https://github.com/nextcloud/desktop.git
synced 2024-11-28 19:58:56 +03:00
Allow to set progress- and log-callback any time.
This commit is contained in:
parent
24a562da49
commit
0d238ae1fe
1 changed files with 0 additions and 11 deletions
11
src/csync.c
11
src/csync.c
|
@ -902,11 +902,6 @@ int csync_set_log_callback(CSYNC *ctx, csync_log_callback cb) {
|
|||
return -1;
|
||||
}
|
||||
|
||||
if (ctx->status & CSYNC_STATUS_INIT) {
|
||||
fprintf(stderr, "csync_set_log_callback: This function must be called before initialization.\n");
|
||||
return -1;
|
||||
}
|
||||
|
||||
ctx->callbacks.log_function = cb;
|
||||
|
||||
return 0;
|
||||
|
@ -1069,12 +1064,6 @@ int csync_set_progress_callback(CSYNC* ctx, csync_progress_callback cb)
|
|||
ctx->error_code = CSYNC_ERR_NONE;
|
||||
ctx->callbacks.progresscb = cb;
|
||||
|
||||
if (ctx->status & CSYNC_STATUS_INIT) {
|
||||
fprintf(stderr, "csync_set_progress_callback: This function must be called before initialization.\n");
|
||||
ctx->error_code = CSYNC_ERR_UNSPEC;
|
||||
return -1;
|
||||
}
|
||||
|
||||
return 0;
|
||||
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue