[PATCH 0/9] Fix directory lookup on read-only databases
Austin Clements
amdragon at MIT.EDU
Thu May 17 21:13:33 PDT 2012
This fixes notmuch_database_get_directory and
notmuch_database_find_message_by_filename so that they don't attempt
to create missing directory documents. This makes them work on
read-only databases (and prevents n_d_f_m_b_f from crashing
unceremoniously on read-only databases).
Unfortunately, there are several functions involved in directory
document lookup, so the first three patches simply add a creation flag
at each necessary layer. The remaining patches then fix up the two
API functions and their uses.
If we do a 0.13.1 bug fix release, these patches could go in to
complement the API changes made in 0.13 to support these fixes. David
can make that call.
There are several patches, but they're all short and incremental.
bindings/python/notmuch/database.py | 11 -----------
lib/database.cc | 40 +++++++++++++++++++++++++---------------
lib/directory.cc | 41 +++++++++++++++++++++++++++++++++++------
lib/message.cc | 11 +++++------
lib/notmuch-private.h | 13 +++++++++++++
lib/notmuch.h | 10 ++--------
notmuch-new.c | 36 +++++++-----------------------------
test/python | 8 ++++++++
8 files changed, 95 insertions(+), 75 deletions(-)
More information about the notmuch
mailing list