Finalize progress before error handling.

This commit is contained in:
Klaas Freitag 2013-08-05 15:38:06 +02:00
parent 721443feea
commit a42d942a35

View file

@ -555,14 +555,14 @@ int csync_propagate(CSYNC *ctx) {
"Propagation for remote replica took %.2f seconds visiting %zu files.", "Propagation for remote replica took %.2f seconds visiting %zu files.",
c_secdiff(finish, start), c_rbtree_size(ctx->remote.tree)); c_secdiff(finish, start), c_rbtree_size(ctx->remote.tree));
csync_finalize_progress(ctx);
if (rc < 0) { if (rc < 0) {
if( ctx->error_code == CSYNC_ERR_NONE ) if( ctx->error_code == CSYNC_ERR_NONE )
ctx->error_code = csync_errno_to_csync_error( CSYNC_ERR_PROPAGATE); ctx->error_code = csync_errno_to_csync_error( CSYNC_ERR_PROPAGATE);
return -1; return -1;
} }
csync_finalize_progress(ctx);
ctx->status |= CSYNC_STATUS_PROPAGATE; ctx->status |= CSYNC_STATUS_PROPAGATE;
return 0; return 0;