X-Git-Url: http://git.madism.org/?a=blobdiff_plain;f=imap%2Futil.c;h=caf1616a96510e769bbb1dc1013f809cc07eef95;hb=0dbe922d4298aed78dcba64b7c770f315a64505e;hp=5ca2fad88e2e2ca75b49fa1f86011db5e2dd8453;hpb=c98480f8568e6c1bc927c6c5f2b5e80b4aa6548c;p=apps%2Fmadmutt.git diff --git a/imap/util.c b/imap/util.c index 5ca2fad..caf1616 100644 --- a/imap/util.c +++ b/imap/util.c @@ -15,15 +15,14 @@ #include #include +#include #include "mutt.h" #include "mx.h" /* for M_IMAP */ -#include "url.h" #include "imap_private.h" -#include "mutt_ssl.h" +#include #include -#include "lib/debug.h" #include #include @@ -80,7 +79,6 @@ int imap_parse_path (const char *path, IMAP_MBOX * mx) ImapPort = ntohs (service->s_port); else ImapPort = IMAP_PORT; - debug_print (3, ("Using default IMAP port %d\n", ImapPort)); } if (!ImapsPort) { service = getservbyname ("imaps", "tcp"); @@ -88,7 +86,6 @@ int imap_parse_path (const char *path, IMAP_MBOX * mx) ImapsPort = ntohs (service->s_port); else ImapsPort = IMAP_SSL_PORT; - debug_print (3, ("Using default IMAPS port %d\n", ImapsPort)); } /* Defaults */ @@ -200,7 +197,7 @@ void imap_free_idata (IMAP_DATA ** idata) return; p_delete(&(*idata)->capstr); - mutt_free_list (&(*idata)->flags); + string_list_wipe(&(*idata)->flags); p_delete(&((*idata)->cmd.buf)); p_delete(idata); } @@ -214,12 +211,12 @@ void imap_free_idata (IMAP_DATA ** idata) * Moreover, IMAP servers may dislike the path ending with the delimiter. */ char *imap_fix_path (IMAP_DATA * idata, char *mailbox, char *path, - size_t plen) + ssize_t plen) { int x = 0; if (!mailbox || !*mailbox) { - strfcpy (path, "INBOX", plen); + m_strcpy(path, plen, "INBOX"); return path; } @@ -292,8 +289,7 @@ char *imap_next_word (char *s) s++; } - SKIPWS (s); - return s; + return vskipspaces(s); } /* imap_parse_date: date is of the form: DD-MMM-YYYY HH:MM:SS +ZZzz */ @@ -475,7 +471,7 @@ int imap_wordcasecmp (const char *a, const char *b) * */ -static RETSIGTYPE alrm_handler (int sig) +static RETSIGTYPE alrm_handler (int sig __attribute__((unused))) { /* empty */ }