mirror of
https://git.notmuchmail.org/git/notmuch
synced 2024-11-22 02:48:08 +01:00
lib: check for writable db in n_m_tags_maildir_flags
The database needs to be writable because the list of stored file names will change in general.
This commit is contained in:
parent
3f27cce71f
commit
6f749dd24a
2 changed files with 4 additions and 1 deletions
|
@ -2039,6 +2039,10 @@ notmuch_message_tags_to_maildir_flags (notmuch_message_t *message)
|
|||
char *to_set, *to_clear;
|
||||
notmuch_status_t status = NOTMUCH_STATUS_SUCCESS;
|
||||
|
||||
status = _notmuch_database_ensure_writable (message->notmuch);
|
||||
if (status)
|
||||
return status;
|
||||
|
||||
_get_maildir_flag_actions (message, &to_set, &to_clear);
|
||||
|
||||
for (filenames = notmuch_message_get_filenames (message);
|
||||
|
|
|
@ -375,7 +375,6 @@ EOF
|
|||
test_expect_equal_file EXPECTED OUTPUT
|
||||
|
||||
test_begin_subtest "Handle converting tags to maildir flags with closed db"
|
||||
test_subtest_known_broken
|
||||
cat c_head - c_tail <<'EOF' | test_C ${MAIL_DIR}
|
||||
{
|
||||
notmuch_status_t status;
|
||||
|
|
Loading…
Reference in a new issue