On 2018-10-05 21:56, Timo Sirainen wrote:

Looks like it works. But could you:


1) Add it to github as merge request

Done, for the first part of the code.

2) MAILBOX_LIST_PATH_TYPE_VOLATILEDIR might be useful, but it's kind of a separate change of its own. To simplify, in Maildir code you could have box->list->set->volatile_dir != NULL ? box->list->set->volatile_dir : control_dir. That way it's falling back to control_dir like the previous code when VOLATILEDIR wasn't set.

I just copied the code from above:
    if (mailbox_get_path_to(box, MAILBOX_LIST_PATH_TYPE_CONTROL,
                                &control_dir) <= 0)

If I do as you suggest, I get this?:

maildir-uidlist.c:277:47: error: dereferencing pointer to incomplete type uidlist->path_dotlock = i_strconcat(box->list->set->volatile_dir != NULL ? box->list->set->volatile_dir : control_dir, "/"MAILDIR_UIDLIST_NAME, NULL);

That's the reason I expanded mailbox_get_path_to(), since that angle worked

Thanks for the feedback :)

--
Tom

Reply via email to