From 242d5a3ed5ed85bb935c8ed4a4678d7596d8534d Mon Sep 17 00:00:00 2001 From: David Bremner Date: Sat, 18 Feb 2017 11:08:04 -0400 Subject: lib: make notmuch_query_add_tag_exclude return a status value Since this is an ABI breaking change, but we already bumped the SONAME for the next release --- notmuch-count.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'notmuch-count.c') diff --git a/notmuch-count.c b/notmuch-count.c index cf80ee25..a05b430d 100644 --- a/notmuch-count.c +++ b/notmuch-count.c @@ -87,8 +87,13 @@ print_count (notmuch_database_t *notmuch, const char *query_str, return -1; } - for (i = 0; i < exclude_tags_length; i++) - notmuch_query_add_tag_exclude (query, exclude_tags[i]); + for (i = 0; i < exclude_tags_length; i++) { + status = notmuch_query_add_tag_exclude (query, exclude_tags[i]); + if (status && status != NOTMUCH_STATUS_IGNORED) { + print_status_query ("notmuch count", query, status); + return -1; + } + } switch (output) { case OUTPUT_MESSAGES: -- cgit v1.2.3