X-Git-Url: http://git.madism.org/?p=apps%2Fmadmutt.git;a=blobdiff_plain;f=send.c;h=ace09c00f759ef3ed68664b930beb3b9c2cd35ba;hp=fd0341be96906d3a7ae4c07025615bdc158c6c3f;hb=284454918cc95058b026d057195eaa5279135c36;hpb=a742b680bdba8cb47d2b81ab3397cdbec7ed5b69 diff --git a/send.c b/send.c index fd0341b..ace09c0 100644 --- a/send.c +++ b/send.c @@ -7,36 +7,15 @@ * please see the file GPL in the top level source directory. */ -#if HAVE_CONFIG_H -# include "config.h" -#endif - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include +#include #include -#include -#include -#include -#include -#include -#include - #include #include - +#include #include #include -#include "mutt.h" #include "alias.h" #include "keymap.h" #include "copy.h" @@ -302,7 +281,7 @@ static int edit_envelope (ENVELOPE * en, int flags) } #ifdef USE_NNTP -char *nntp_get_header(const char *s) +static char *nntp_get_header(const char *s) { return m_strdup(skipspaces(s)); } @@ -585,25 +564,6 @@ int mutt_fetch_recips (ENVELOPE * out, ENVELOPE * in, int flags) return 0; } -string_list_t *mutt_make_references (ENVELOPE * e) -{ - string_list_t *t = NULL, *l = NULL; - - if (e->references) - l = string_list_dup(e->references); - else - l = string_list_dup(e->in_reply_to); - - if (e->message_id) { - t = string_item_new(); - t->data = m_strdup(e->message_id); - t->next = l; - l = t; - } - - return l; -} - void mutt_fix_reply_recipients (ENVELOPE * env) { mutt_expand_aliases_env (env); @@ -617,8 +577,8 @@ void mutt_fix_reply_recipients (ENVELOPE * env) } /* the CC field can get cluttered, especially with lists */ - env->to = mutt_remove_duplicates (env->to); - env->cc = mutt_remove_duplicates (env->cc); + address_list_uniq(env->to); + address_list_uniq(env->cc); env->cc = mutt_remove_xrefs (env->to, env->cc); if (env->cc && !env->to) { @@ -656,6 +616,25 @@ void mutt_make_misc_reply_headers (ENVELOPE * env, CONTEXT * ctx, #endif } +static string_list_t *mutt_make_references (ENVELOPE * e) +{ + string_list_t *t = NULL, *l = NULL; + + if (e->references) + l = string_list_dup(e->references); + else + l = string_list_dup(e->in_reply_to); + + if (e->message_id) { + t = string_item_new(); + t->data = m_strdup(e->message_id); + t->next = l; + l = t; + } + + return l; +} + void mutt_add_to_reference_headers (ENVELOPE * env, ENVELOPE * curenv, string_list_t *** pp, string_list_t *** qq) { @@ -925,7 +904,7 @@ void mutt_set_followup_to (ENVELOPE * e) } } - e->mail_followup_to = mutt_remove_duplicates(e->mail_followup_to); + address_list_uniq(e->mail_followup_to); } }