aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/plugins/Matrix.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/plugins/Matrix.cpp b/src/plugins/Matrix.cpp
index d6034de..ce003a0 100644
--- a/src/plugins/Matrix.cpp
+++ b/src/plugins/Matrix.cpp
@@ -1099,12 +1099,8 @@ namespace QuickMedia {
}
#endif
- sync_end:
- if(sync_running)
- std::this_thread::sleep_for(std::chrono::milliseconds(500));
-
// TODO: Circulate file
- FILE *sync_cache_file = fopen(matrix_cache_dir.data.c_str(), initial_sync ? "wb" : "ab");
+ sync_cache_file = fopen(matrix_cache_dir.data.c_str(), initial_sync ? "wb" : "ab");
initial_sync = false;
if(sync_cache_file) {
if(json_root.IsObject()) {
@@ -1116,6 +1112,10 @@ namespace QuickMedia {
}
fclose(sync_cache_file);
}
+
+ sync_end:
+ if(sync_running)
+ std::this_thread::sleep_for(std::chrono::milliseconds(500));
}
});
}