Only reload if data files were changed
Instead of blindly reloading data in io_reload_data(), compare the stored hashes of the data files with hashes of the current file contents and only reload if any of the hashes differs. Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
This commit is contained in:
@@ -277,11 +277,12 @@ static inline void key_generic_save(void)
|
||||
|
||||
static inline void key_generic_reload(void)
|
||||
{
|
||||
io_reload_data();
|
||||
do_storage(0);
|
||||
notify_check_next_app(1);
|
||||
ui_calendar_monthly_view_cache_set_invalid();
|
||||
wins_update(FLAG_ALL);
|
||||
if (io_reload_data()) {
|
||||
do_storage(0);
|
||||
notify_check_next_app(1);
|
||||
ui_calendar_monthly_view_cache_set_invalid();
|
||||
wins_update(FLAG_ALL);
|
||||
}
|
||||
}
|
||||
|
||||
static inline void key_generic_import(void)
|
||||
|
||||
Reference in New Issue
Block a user