diff options
author | Carl Worth <cworth@cworth.org> | 2009-10-27 23:57:37 -0700 |
---|---|---|
committer | Carl Worth <cworth@cworth.org> | 2009-10-27 23:57:37 -0700 |
commit | 07aa759b68f3198e565385eb23736984bb378d0f (patch) | |
tree | 1932f457e7b377933f0674ff3fe45055234c0ab0 /database.cc | |
parent | 5eaec1e31679d2a1a9ea3b32fb306ad67ee1a936 (diff) |
Fix segfault in case of the database lock not being available.
We were nicely reporting the lock-aquisition failure, but then marching
along trying to use the database object and just crashing badly.
So don't do that.
Diffstat (limited to 'database.cc')
-rw-r--r-- | database.cc | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/database.cc b/database.cc index 5555b0e..71246eb 100644 --- a/database.cc +++ b/database.cc @@ -489,6 +489,7 @@ notmuch_database_open (const char *path) } catch (const Xapian::Error &error) { fprintf (stderr, "A Xapian exception occurred: %s\n", error.get_msg().c_str()); + notmuch = NULL; } DONE: |