]> git.notmuchmail.org Git - notmuch/blobdiff - lib/message.cc
Correct some minor typos in a comment
[notmuch] / lib / message.cc
index c2da25c953a46d04e82473cd921ad581495ba4e9..ad2208976729d653fc5162ec8b6d0823e6b5e1a5 100644 (file)
@@ -50,7 +50,7 @@ struct maildir_flag_tag {
 };
 
 /* ASCII ordered table of Maildir flags and associated tags */
-struct maildir_flag_tag flag2tag[] = {
+static struct maildir_flag_tag flag2tag[] = {
     { 'D', "draft",   false},
     { 'F', "flagged", false},
     { 'P', "passed",  false},
@@ -132,8 +132,8 @@ _notmuch_message_create_for_document (const void *talloc_owner,
  *
  * Here, 'talloc owner' is an optional talloc context to which the new
  * message will belong. This allows for the caller to not bother
- * calling notmuch_message_destroy on the message, and no that all
- * memory will be reclaimed with 'talloc_owner' is free. The caller
+ * calling notmuch_message_destroy on the message, and know that all
+ * memory will be reclaimed when 'talloc_owner' is freed. The caller
  * still can call notmuch_message_destroy when finished with the
  * message if desired.
  *
@@ -254,6 +254,12 @@ _notmuch_message_create_for_message_id (notmuch_database_t *notmuch,
     return message;
 }
 
+unsigned int
+_notmuch_message_get_doc_id (notmuch_message_t *message)
+{
+    return message->doc_id;
+}
+
 const char *
 notmuch_message_get_message_id (notmuch_message_t *message)
 {
@@ -459,7 +465,7 @@ _notmuch_message_add_filename (notmuch_message_t *message,
  * This change will not be reflected in the database until the next
  * call to _notmuch_message_sync.
  */
-notmuch_status_t
+static notmuch_status_t
 _notmuch_message_rename (notmuch_message_t *message,
                         const char *old_filename,
                         const char *new_filename)
@@ -1122,7 +1128,7 @@ notmuch_message_tags_to_maildir_flags (notmuch_message_t *message)
     const char *filename;
     char *filename_new;
     char *to_set, *to_clear;
-    notmuch_status_t status;
+    notmuch_status_t status = NOTMUCH_STATUS_SUCCESS;
 
     _get_maildir_flag_actions (message, &to_set, &to_clear);