diff options
author | Camila San <hello@camila.codes> | 2019-02-04 17:10:29 +0300 |
---|---|---|
committer | Camila San <hello@camila.codes> | 2019-02-04 17:10:29 +0300 |
commit | 706cfe88d0b8e98347372c32db7d462f4a26ee58 (patch) | |
tree | 3b1654a2f6ed6c1e6bb5ce15928598eea312cb2e | |
parent | 653c10be86faf9e84fd2574be0e3eda2e91b721b (diff) |
Fixes syncing in sub directories.techpreview-v1
Signed-off-by: Camila San <hello@camila.codes>
-rw-r--r-- | src/csync/csync_reconcile.cpp | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/src/csync/csync_reconcile.cpp b/src/csync/csync_reconcile.cpp index 68457f64c..f89774d13 100644 --- a/src/csync/csync_reconcile.cpp +++ b/src/csync/csync_reconcile.cpp @@ -369,8 +369,13 @@ static void _csync_merge_algorithm_visitor(csync_file_stat_t *cur, CSYNC * ctx) cur->instruction = CSYNC_INSTRUCTION_NONE; if (is_conflict) other->instruction = CSYNC_INSTRUCTION_CONFLICT; - else - other->instruction = !cur->is_fuse_created_file ? CSYNC_INSTRUCTION_UPDATE_METADATA : CSYNC_INSTRUCTION_SYNC; + else { + if(other->type == ItemTypeDirectory && cur->type == ItemTypeDirectory) + other->instruction = CSYNC_INSTRUCTION_UPDATE_METADATA; + else + other->instruction = (!cur->is_fuse_created_file) ? CSYNC_INSTRUCTION_UPDATE_METADATA : CSYNC_INSTRUCTION_SYNC; + } + } break; |