mirror of
https://git.notmuchmail.org/git/notmuch
synced 2024-12-22 17:34:54 +01:00
Prevent data loss caused by SIGINT during notmuch new
When Ctrl-C is pressed in a wrong time during notmuch new, it can lead to removal of messages from the database even if the files were not removed. It happened at least once to me. Signed-off-by: Michal Sojka <sojkam1@fel.cvut.cz>
This commit is contained in:
parent
9ddde6eb14
commit
4234215263
1 changed files with 3 additions and 0 deletions
|
@ -454,6 +454,9 @@ add_files_recursive (notmuch_database_t *notmuch,
|
|||
next = NULL;
|
||||
}
|
||||
|
||||
if (interrupted)
|
||||
goto DONE;
|
||||
|
||||
/* Now that we've walked the whole filesystem list, anything left
|
||||
* over in the database lists has been deleted. */
|
||||
while (notmuch_filenames_valid (db_files))
|
||||
|
|
Loading…
Reference in a new issue