*
* It would be nice to do the upgrade of the document directly
* here, but the database is likely open in read-only mode. */
- const char *data;
- data = message->doc.get_data ().c_str ();
+ std::string datastr = message->doc.get_data ();
+ const char *data = datastr.c_str ();
if (data == NULL)
INTERNAL_ERROR ("message with no filename");
query = notmuch_query_create (notmuch, query_string);
if (query == NULL)
return NOTMUCH_STATUS_OUT_OF_MEMORY;
- status = notmuch_query_count_messages_st (query, &count);
+ status = notmuch_query_count_messages (query, &count);
if (status) {
notmuch_query_destroy (query);
return status;