projects
/
notmuch.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
c44db65
)
lib: migrate notmuch_database_upgrade to new query_search API
author
David Bremner
<david@tethera.net>
Sun, 27 Sep 2015 15:32:01 +0000
(12:32 -0300)
committer
David Bremner
<david@tethera.net>
Mon, 5 Oct 2015 22:53:11 +0000
(19:53 -0300)
Here we depend on the error path cleaning up query
lib/database.cc
patch
|
blob
|
history
diff --git
a/lib/database.cc
b/lib/database.cc
index f39d4485076cf9e855f6d7fe2401d4b1cf1894b4..5e86955d8dfd91b3880a5d53217b9265eb69c65e 100644
(file)
--- a/
lib/database.cc
+++ b/
lib/database.cc
@@
-1450,9
+1450,10
@@
notmuch_database_upgrade (notmuch_database_t *notmuch,
query = notmuch_query_create (notmuch, "");
- /* XXX: this should use the _st version, but needs an error
- path */
- for (messages = notmuch_query_search_messages (query);
+ status = notmuch_query_search_messages_st (query, &messages);
+ if (status)
+ goto DONE;
+ for (;
notmuch_messages_valid (messages);
notmuch_messages_move_to_next (messages))
{