We had documented both notmuch_thread_results_get and
notmuch_message_results_get to return NULL if (! has_more)
but we hadn't actually implemented that. Fix.
Xapian::docid doc_id;
notmuch_private_status_t status;
+ if (! notmuch_message_results_has_more (results))
+ return NULL;
+
doc_id = *results->iterator;
message = _notmuch_message_create (results,
notmuch_thread_t *thread;
const char *thread_id;
+ if (! notmuch_thread_results_has_more (results))
+ return NULL;
+
thread_id = (const char *) g_ptr_array_index (results->thread_ids,
results->index);