X-Git-Url: https://git.notmuchmail.org/git?p=notmuch;a=blobdiff_plain;f=notmuch-reply.c;h=1357142903d5771566678a132f15c6537e4e7714;hp=fd6a1ec1b11ddb5d9def9ae88f1aa4c59a4ea31a;hb=391d9f94204234d6ef3dd701d69bfdf92dbad8f0;hpb=33c8777a967ece2dd4bbda7e83a4e07c195abf51 diff --git a/notmuch-reply.c b/notmuch-reply.c index fd6a1ec1..13571429 100644 --- a/notmuch-reply.c +++ b/notmuch-reply.c @@ -655,9 +655,14 @@ notmuch_reply_format_sprinter(void *ctx, notmuch_messages_t *messages; notmuch_message_t *message; mime_node_t *node; + unsigned count; notmuch_status_t status; - if (notmuch_query_count_messages (query) != 1) { + status = notmuch_query_count_messages_st (query, &count); + if (print_status_query ("notmuch reply", query, status)) + return 1; + + if (count != 1) { fprintf (stderr, "Error: search term did not match precisely one message.\n"); return 1; }