X-Git-Url: https://git.notmuchmail.org/git?p=notmuch;a=blobdiff_plain;f=notmuch-new.c;h=d45d0af8642a3f2f4815808c91509e5a0145eda6;hp=442a2f0ae2886c169881dab4ae9e35bf20f77bec;hb=e26d99dc7b02f33299c281f97a13deaef802bc7a;hpb=727fcd18c6a3897622582e71a2d71081e3ae40ea diff --git a/notmuch-new.c b/notmuch-new.c index 442a2f0a..d45d0af8 100644 --- a/notmuch-new.c +++ b/notmuch-new.c @@ -878,17 +878,11 @@ _remove_directory (void *ctx, goto DONE; } - /* - * XXX: The library does not have a function to remove a directory - * document for a path. Usually this doesn't matter except for a - * slight waste of space. However, if the directory gets added to - * the filesystem again, the old directory document is found with - * the old mtime. Reset the directory mtime to avoid problems. - */ - notmuch_directory_set_mtime (directory, 0); + status = notmuch_directory_delete (directory); DONE: - notmuch_directory_destroy (directory); + if (status) + notmuch_directory_destroy (directory); return status; }