summaryrefslogtreecommitdiffstats
path: root/notmuch-count.c
diff options
context:
space:
mode:
authorDavid Bremner <david@tethera.net>2017-02-18 11:08:04 -0400
committerDavid Bremner <david@tethera.net>2017-03-22 08:47:13 -0300
commit242d5a3ed5ed85bb935c8ed4a4678d7596d8534d (patch)
tree19dd13df847db2aa51a6b17eaef77264524d4002 /notmuch-count.c
parent3721bd45d72e50436ee760b03ae533d49bbb8724 (diff)
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
Diffstat (limited to 'notmuch-count.c')
-rw-r--r--notmuch-count.c9
1 files changed, 7 insertions, 2 deletions
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: