<<< Date Index >>>     <<< Thread Index >>>

Re: Customize To: field



Seems fine. Does anyone object?

On Tuesday, 18 November 2008 at 01:59, TAKAHASHI Tamotsu wrote:
> * Mon Nov 17 2008 Michael Elkins <me@xxxxxxxxxx>
> > What does mutt-dev think about making $reverse_alias apply to replies?
> 
> It looks easy.
> I don't set $reverse_alias though.
> 

> diff -r 8199185fa595 send.c
> +++ b/send.c  Tue Nov 18 01:53:21 2008 +0900
> @@ -192,11 +192,23 @@
>    char buf[HUGE_STRING];
>    char *err = NULL;
>    int idna_ok = 0;
> +  ADDRESS *rev, *i;
>    
>    do
>    {
>      buf[0] = 0;
>      mutt_addrlist_to_local (*a);
> +    if (option (OPTREVALIAS))
> +    {
> +      for (i = *a; i; i = i->next)
> +      {
> +     if ((rev = alias_reverse_lookup (i)) && rev->personal)
> +     {
> +       FREE (&i->personal);
> +       i->personal = safe_strdup (rev->personal);
> +     }
> +      }
> +    }
>      rfc822_write_address (buf, sizeof (buf), *a, 0);
>      if (mutt_get_field (field, buf, sizeof (buf), M_ALIAS) != 0)
>        return (-1);