projects
/
unix-history
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
tags
|
clone url
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
use -s flag on dequote map to indicate space substitution
[unix-history]
/
usr
/
src
/
usr.sbin
/
sendmail
/
src
/
parseaddr.c
diff --git
a/usr/src/usr.sbin/sendmail/src/parseaddr.c
b/usr/src/usr.sbin/sendmail/src/parseaddr.c
index
8ce3be0
..
3980e66
100644
(file)
--- a/
usr/src/usr.sbin/sendmail/src/parseaddr.c
+++ b/
usr/src/usr.sbin/sendmail/src/parseaddr.c
@@
-7,7
+7,7
@@
*/
#ifndef lint
*/
#ifndef lint
-static char sccsid[] = "@(#)parseaddr.c 8.3
7
(Berkeley) %G%";
+static char sccsid[] = "@(#)parseaddr.c 8.3
8
(Berkeley) %G%";
#endif /* not lint */
#include "sendmail.h"
#endif /* not lint */
#include "sendmail.h"
@@
-2226,6
+2226,10
@@
dequote_init(map, args)
case 'a':
map->map_app = ++p;
break;
case 'a':
map->map_app = ++p;
break;
+
+ case 's':
+ map->map_coldelim = *++p;
+ break;
}
while (*p != '\0' && !(isascii(*p) && isspace(*p)))
p++;
}
while (*p != '\0' && !(isascii(*p) && isspace(*p)))
p++;
@@
-2262,19
+2266,13
@@
dequote_map(map, name, av, statp)
register char *p;
register char *q;
register char c;
register char *p;
register char *q;
register char c;
- int anglecnt;
- int cmntcnt;
- int quotecnt;
- int spacecnt;
- bool quotemode;
- bool bslashmode;
-
- anglecnt = 0;
- cmntcnt = 0;
- quotecnt = 0;
- spacecnt = 0;
- quotemode = FALSE;
- bslashmode = FALSE;
+ int anglecnt = 0;
+ int cmntcnt = 0;
+ int quotecnt = 0;
+ int spacecnt = 0;
+ bool quotemode = FALSE;
+ bool bslashmode = FALSE;
+ char spacesub = map->map_coldelim;
for (p = q = name; (c = *p++) != '\0'; )
{
for (p = q = name; (c = *p++) != '\0'; )
{
@@
-2285,8
+2283,8
@@
dequote_map(map, name, av, statp)
continue;
}
continue;
}
- if (c == ' ' &&
SpaceS
ub != '\0')
- c =
SpaceS
ub;
+ if (c == ' ' &&
spaces
ub != '\0')
+ c =
spaces
ub;
switch (c)
{
switch (c)
{