diff options
author | kim <kim> | 2000-05-20 01:08:31 +0000 |
---|---|---|
committer | kim <kim> | 2000-05-20 01:08:31 +0000 |
commit | 8c9501b5c380b2a4aa6aa4d33a482f433f265182 (patch) | |
tree | 13d635217c0b3cfff2f34ee4bd44248aafa55cfe /mail | |
parent | fd4eb05d8297a0db4dd1fb654a9f6c28c028cee6 (diff) | |
download | pkgsrc-8c9501b5c380b2a4aa6aa4d33a482f433f265182.tar.gz |
Expand & in pw_gecos.
Diffstat (limited to 'mail')
-rw-r--r-- | mail/mutt/files/patch-sum | 6 | ||||
-rw-r--r-- | mail/mutt/patches/patch-aa | 13 | ||||
-rw-r--r-- | mail/mutt/patches/patch-ab | 40 | ||||
-rw-r--r-- | mail/mutt/patches/patch-ac | 10 |
4 files changed, 67 insertions, 2 deletions
diff --git a/mail/mutt/files/patch-sum b/mail/mutt/files/patch-sum index 483d2e4bc34..bace42b7a6b 100644 --- a/mail/mutt/files/patch-sum +++ b/mail/mutt/files/patch-sum @@ -1,3 +1,5 @@ -$NetBSD: patch-sum,v 1.3 1999/08/24 18:12:13 tron Exp $ +$NetBSD: patch-sum,v 1.4 2000/05/20 01:08:31 kim Exp $ -MD5 (patch-aa) = 2bba3aec1076abbc906ea97d54ad3179 +MD5 (patch-aa) = 6bb37ef1e6af29438edcd1e0033d2242 +MD5 (patch-ab) = 2c12d6269e8e691075ca67058e86f74d +MD5 (patch-ac) = e4742b95887fcfe88c15d685bded7174 diff --git a/mail/mutt/patches/patch-aa b/mail/mutt/patches/patch-aa new file mode 100644 index 00000000000..aea8a95d5ed --- /dev/null +++ b/mail/mutt/patches/patch-aa @@ -0,0 +1,13 @@ +$NetBSD: patch-aa,v 1.3 2000/05/20 01:08:32 kim Exp $ + +--- alias.c.orig Sat Mar 4 03:40:52 2000 ++++ alias.c Fri May 19 20:52:33 2000 +@@ -100,6 +100,8 @@ + + strfcpy (a->personal, pw->pw_gecos + pat_match[0].rm_so, + pat_match[0].rm_eo - pat_match[0].rm_so + 1); ++ if (strchr (a->personal, '&')) ++ a->personal = mutt_expand_realname (a->personal, pw->pw_name); + } + + #ifdef EXACT_ADDRESS diff --git a/mail/mutt/patches/patch-ab b/mail/mutt/patches/patch-ab new file mode 100644 index 00000000000..aa65aefbb6b --- /dev/null +++ b/mail/mutt/patches/patch-ab @@ -0,0 +1,40 @@ +$NetBSD: patch-ab,v 1.5 2000/05/20 01:08:32 kim Exp $ + +--- init.c.orig Sat Apr 22 05:27:07 2000 ++++ init.c Fri May 19 20:55:47 2000 +@@ -1674,6 +1674,8 @@ + Realname = mutt_substrdup (pw->pw_gecos, p); + else + Realname = safe_strdup (pw->pw_gecos); ++ if (strchr (Realname, '&')) ++ Realname = mutt_expand_realname (Realname, Username); + Shell = safe_strdup (pw->pw_shell); + } + else +@@ -1890,4 +1892,26 @@ + if (c->func == mutt_parse_hook && mutt_strcasecmp (c->name, name) == 0) + return c->data; + return 0; ++} ++ ++char *mutt_expand_realname(char *gecos, const char *login) ++{ ++ char *buf, *bp, *p; ++ ++ buf = bp = safe_malloc(strlen(gecos) + strlen(login)); ++ ++ /* copy gecos, interpolating & to be full name */ ++ for (p = gecos; *p != '\0'; p++) { ++ if (*p == '&') { ++ sprintf(bp, "%s", login); ++ *bp = toupper(*bp); ++ bp += strlen(bp); ++ } ++ else ++ *bp++ = *p; ++ } ++ *bp = '\0'; ++ ++ safe_free((void **)&gecos); ++ return(buf); + } diff --git a/mail/mutt/patches/patch-ac b/mail/mutt/patches/patch-ac new file mode 100644 index 00000000000..98dbb90221b --- /dev/null +++ b/mail/mutt/patches/patch-ac @@ -0,0 +1,10 @@ +$NetBSD: patch-ac,v 1.1 2000/05/20 01:08:32 kim Exp $ + +--- protos.h.orig Tue Mar 7 06:13:38 2000 ++++ protos.h Fri May 19 20:56:17 2000 +@@ -437,4 +437,4 @@ + void ci_bounce_message (HEADER *, int *); + int ci_send_message (int, HEADER *, char *, CONTEXT *, HEADER *); + +- ++char *mutt_expand_realname(char *, const char *); |