]> granicus.if.org Git - neomutt/commitdiff
imap: rename ImapMailboxData to ImapMboxData 1415/head
authorMehdi Abaakouk <sileht@sileht.net>
Thu, 15 Nov 2018 13:50:17 +0000 (14:50 +0100)
committerMehdi Abaakouk <sileht@sileht.net>
Thu, 15 Nov 2018 13:50:17 +0000 (14:50 +0100)
imap/browse.c
imap/command.c
imap/imap.c
imap/imap_private.h
imap/message.c
imap/util.c

index 721cf47574ffa86d3a2f0faef08096d4dec1714b..797c14a2fd6882be1529d1b34b99da8c3968a36a 100644 (file)
@@ -367,7 +367,7 @@ fail:
 int imap_mailbox_create(const char *path)
 {
   struct ImapAccountData *adata = NULL;
-  struct ImapMailboxData *mdata = NULL;
+  struct ImapMboxData *mdata = NULL;
   char name[LONG_STRING];
   short n;
 
@@ -419,7 +419,7 @@ err:
 int imap_mailbox_rename(const char *path)
 {
   struct ImapAccountData *adata = NULL;
-  struct ImapMailboxData *mdata = NULL;
+  struct ImapMboxData *mdata = NULL;
   char buf[PATH_MAX];
   char newname[PATH_MAX];
 
index 09a33f9eb9c94dd90fa0ddbd728ee515422f9c11..cf1438b5e5fa7602e737610f5980850f19e1cbf4 100644 (file)
@@ -869,7 +869,7 @@ static void cmd_parse_status(struct ImapAccountData *adata, char *s)
     struct ImapAccountData *m_adata = imap_adata_get(np->m);
     if (imap_account_match(&adata->conn_account, &m_adata->conn_account))
     {
-      struct ImapMailboxData *mdata = imap_mdata_get(np->m);
+      struct ImapMboxData *mdata = imap_mdata_get(np->m);
       if (mdata && imap_mxcmp(mailbox, mdata->name) == 0)
       {
         mutt_debug(3, "Found %s in mailbox list (OV: %u ON: %u U: %d)\n",
index 3816c78face3d4e17516ca7a6b4c5b5dacab7ee8..543087b3005801b1b34fc4b66ad49f96e085b26e 100644 (file)
@@ -340,7 +340,7 @@ int imap_prepare_mailbox(struct Mailbox *m)
   if (!m || !m->account)
     return -1;
 
-  struct ImapMailboxData *mdata;
+  struct ImapMboxData *mdata;
   struct ImapAccountData *adata = m->account->adata;
 
   mutt_account_hook(m->realpath);
@@ -674,7 +674,7 @@ int imap_create_mailbox(struct ImapAccountData *adata, char *mailbox)
 int imap_access(const char *path)
 {
   struct ImapAccountData *adata = NULL;
-  struct ImapMailboxData *mdata = NULL;
+  struct ImapMboxData *mdata = NULL;
   int rc;
 
   if (imap_adata_find(path, &adata, &mdata) < 0)
@@ -1351,7 +1351,7 @@ int imap_check(struct ImapAccountData *adata, bool force)
 int imap_mailbox_check(struct Mailbox *m, bool check_stats)
 {
   struct ImapAccountData *adata = NULL;
-  struct ImapMailboxData *mdata = NULL;
+  struct ImapMboxData *mdata = NULL;
   char command[LONG_STRING * 2];
 
   if (imap_prepare_mailbox(m))
@@ -1421,7 +1421,7 @@ int imap_status(const char *path, bool queue)
   static int queued = 0;
 
   struct ImapAccountData *adata = NULL;
-  struct ImapMailboxData *mdata = NULL;
+  struct ImapMboxData *mdata = NULL;
   char buf[LONG_STRING * 2];
   struct ImapStatus *status = NULL;
 
@@ -1594,7 +1594,7 @@ int imap_search(struct Mailbox *m, const struct Pattern *pat)
 int imap_subscribe(char *path, bool subscribe)
 {
   struct ImapAccountData *adata = NULL;
-  struct ImapMailboxData *mdata = NULL;
+  struct ImapMboxData *mdata = NULL;
   char buf[LONG_STRING * 2];
   char mbox[LONG_STRING];
   char errstr[STRING];
@@ -1652,7 +1652,7 @@ int imap_subscribe(char *path, bool subscribe)
 int imap_complete(char *buf, size_t buflen, char *path)
 {
   struct ImapAccountData *adata = NULL;
-  struct ImapMailboxData *mdata = NULL;
+  struct ImapMboxData *mdata = NULL;
   char tmp[LONG_STRING * 2];
   struct ImapList listresp;
   char completion[LONG_STRING];
@@ -1738,7 +1738,7 @@ int imap_fast_trash(struct Mailbox *m, char *dest)
 
   struct ImapAccountData *adata = imap_adata_get(m);
   struct ImapAccountData *dest_adata = NULL;
-  struct ImapMailboxData *dest_mdata = NULL;
+  struct ImapMboxData *dest_mdata = NULL;
 
   if (imap_adata_find(dest, &dest_adata, &dest_mdata) < 0)
     return -1;
@@ -2176,7 +2176,7 @@ static int imap_mbox_open(struct Context *ctx)
     return -1;
 
   struct ImapAccountData *adata = m->account->adata;
-  struct ImapMailboxData *mdata = m->mdata;
+  struct ImapMboxData *mdata = m->mdata;
 
   FREE(&(adata->mbox_name));
   adata->mbox_name = mutt_str_strdup(mdata->name);
@@ -2420,7 +2420,7 @@ static int imap_mbox_open_append(struct Mailbox *m, int flags)
     return -1;
 
   struct ImapAccountData *adata = m->account->adata;
-  struct ImapMailboxData *mdata = m->mdata;
+  struct ImapMboxData *mdata = m->mdata;
 
   rc = imap_access2(adata, mdata->name);
   if (rc == 0)
index 4beab47fc3bd94ee320516e0827e0613232d0ac6..87f4bed20e45487e266c1e4c35fbc58677fe4a14 100644 (file)
@@ -274,11 +274,11 @@ struct ImapAccountData
 };
 
 /**
- * struct ImapMailboxData - IMAP-specific Mailbox data
+ * struct ImapMboxData - IMAP-specific Mailbox data
  *
  * This data is specific to a Mailbox of an IMAP server
  */
-struct ImapMailboxData
+struct ImapMboxData
 {
   char *name;
   char *munge_name;
@@ -317,7 +317,7 @@ int imap_login(struct ImapAccountData *adata);
 void imap_logout(struct ImapAccountData **adata);
 int imap_sync_message_for_copy(struct ImapAccountData *adata, struct Email *e, struct Buffer *cmd, int *err_continue);
 bool imap_has_flag(struct ListHead *flag_list, const char *flag);
-int imap_adata_find(const char *path, struct ImapAccountData **adata, struct ImapMailboxData **mdata);
+int imap_adata_find(const char *path, struct ImapAccountData **adata, struct ImapMboxData **mdata);
 
 /* auth.c */
 int imap_authenticate(struct ImapAccountData *adata);
@@ -346,7 +346,7 @@ int imap_msg_commit(struct Mailbox *m, struct Message *msg);
 
 /* util.c */
 struct ImapAccountData *imap_adata_get(struct Mailbox *m);
-struct ImapMailboxData *imap_mdata_get(struct Mailbox *m);
+struct ImapMboxData *imap_mdata_get(struct Mailbox *m);
 #ifdef USE_HCACHE
 header_cache_t *imap_hcache_open(struct ImapAccountData *adata, const char *path);
 void imap_hcache_close(struct ImapAccountData *adata);
@@ -362,7 +362,7 @@ int imap_continue(const char *msg, const char *resp);
 void imap_error(const char *where, const char *msg);
 struct ImapAccountData *imap_adata_new(void);
 void imap_adata_free(void **ptr);
-struct ImapMailboxData *imap_mdata_new(struct ImapAccountData *adata, const char* name);
+struct ImapMboxData *imap_mdata_new(struct ImapAccountData *adata, const char* name);
 void imap_mdata_free(void **ptr);
 char *imap_fix_path(struct ImapAccountData *adata, const char *mailbox, char *path, size_t plen);
 void imap_cachepath(struct ImapAccountData *adata, const char *mailbox, char *dest, size_t dlen);
index a080af4954e304f9953ef49921fa6d8dbfbdf682..4b753bd806e91d7789cd0444be0a7ab22e46b818 100644 (file)
@@ -1391,7 +1391,7 @@ int imap_append_message(struct Mailbox *m, struct Message *msg)
   int rc;
 
   struct ImapAccountData *adata = imap_adata_get(m);
-  struct ImapMailboxData *mdata = imap_mdata_get(m);
+  struct ImapMboxData *mdata = imap_mdata_get(m);
 
   fp = fopen(msg->path, "r");
   if (!fp)
index e3a2fe0e3d390d0562179ef4e789028241269b24..3168729550e2552917b1ddcb29713a9ad069d5e9 100644 (file)
@@ -127,7 +127,7 @@ struct ImapAccountData *imap_adata_get(struct Mailbox *m)
  * imap_adata_find - Find the Account data for this path
  */
 int imap_adata_find(const char *path, struct ImapAccountData **adata,
-                    struct ImapMailboxData **mdata)
+                    struct ImapMboxData **mdata)
 {
   struct ConnAccount conn_account;
   struct ImapAccountData *tmp_adata;
@@ -155,13 +155,13 @@ int imap_adata_find(const char *path, struct ImapAccountData **adata,
 }
 
 /**
- * imap_mdata_new - Allocate and initialise a new ImapMailboxData structure
- * @retval ptr New ImapMailboxData
+ * imap_mdata_new - Allocate and initialise a new ImapMboxData structure
+ * @retval ptr New ImapMboxData
  */
-struct ImapMailboxData *imap_mdata_new(struct ImapAccountData *adata, const char *name)
+struct ImapMboxData *imap_mdata_new(struct ImapAccountData *adata, const char *name)
 {
   char buf[LONG_STRING];
-  struct ImapMailboxData *mdata = mutt_mem_calloc(1, sizeof(struct ImapMailboxData));
+  struct ImapMboxData *mdata = mutt_mem_calloc(1, sizeof(struct ImapMboxData));
 
   mdata->real_name = mutt_str_strdup(name);
 
@@ -177,7 +177,7 @@ struct ImapMailboxData *imap_mdata_new(struct ImapAccountData *adata, const char
 }
 
 /**
- * imap_mdata_free - Release and clear storage in an ImapMailboxData structure
+ * imap_mdata_free - Release and clear storage in an ImapMboxData structure
  * @param ptr Imap Mailbox data
  */
 void imap_mdata_free(void **ptr)
@@ -185,7 +185,7 @@ void imap_mdata_free(void **ptr)
   if (!ptr || !*ptr)
     return;
 
-  struct ImapMailboxData *mdata = *ptr;
+  struct ImapMboxData *mdata = *ptr;
 
   FREE(&mdata->name);
   FREE(&mdata->real_name);
@@ -196,7 +196,7 @@ void imap_mdata_free(void **ptr)
 /**
  * imap_mdata_get - Get the Mailbox data for this mailbox
  */
-struct ImapMailboxData *imap_mdata_get(struct Mailbox *m)
+struct ImapMboxData *imap_mdata_get(struct Mailbox *m)
 {
   if (!m || (m->magic != MUTT_IMAP) || !m->mdata)
     return NULL;
@@ -259,7 +259,7 @@ void imap_get_parent(const char *mbox, char delim, char *buf, size_t buflen)
 void imap_get_parent_path(const char *path, char *buf, size_t buflen)
 {
   struct ImapAccountData *adata = NULL;
-  struct ImapMailboxData *mdata = NULL;
+  struct ImapMboxData *mdata = NULL;
   char mbox[LONG_STRING];
 
   if (imap_adata_find(path, &adata, &mdata) < 0)
@@ -286,7 +286,7 @@ void imap_get_parent_path(const char *path, char *buf, size_t buflen)
 void imap_clean_path(char *path, size_t plen)
 {
   struct ImapAccountData *adata = NULL;
-  struct ImapMailboxData *mdata = NULL;
+  struct ImapMboxData *mdata = NULL;
 
   if (imap_adata_find(path, &adata, &mdata) < 0)
     return;
@@ -383,7 +383,7 @@ header_cache_t *imap_hcache_open(struct ImapAccountData *adata, const char *path
     imap_cachepath(adata, path, mbox, sizeof(mbox));
   else if (adata->mailbox)
   {
-    struct ImapMailboxData *mdata = imap_mdata_get(adata->mailbox);
+    struct ImapMboxData *mdata = imap_mdata_get(adata->mailbox);
     imap_cachepath(adata, mdata->name, mbox, sizeof(mbox));
   }
   else