diff options
Diffstat (limited to 'usr.bin/mail/names.c')
-rw-r--r-- | usr.bin/mail/names.c | 59 |
1 files changed, 17 insertions, 42 deletions
diff --git a/usr.bin/mail/names.c b/usr.bin/mail/names.c index d1cf3d6..8697f7b 100644 --- a/usr.bin/mail/names.c +++ b/usr.bin/mail/names.c @@ -51,9 +51,7 @@ __FBSDID("$FreeBSD$"); * name and return it. */ struct name * -nalloc(str, ntype) - char str[]; - int ntype; +nalloc(char str[], int ntype) { struct name *np; @@ -69,8 +67,7 @@ nalloc(str, ntype) * Find the tail of a list and return it. */ struct name * -tailof(name) - struct name *name; +tailof(struct name *name) { struct name *np; @@ -88,9 +85,7 @@ tailof(name) * Return the list or NULL if none found. */ struct name * -extract(line, ntype) - char line[]; - int ntype; +extract(char line[], int ntype) { char *cp, *nbuf; struct name *top, *np, *t; @@ -119,9 +114,7 @@ extract(line, ntype) * Turn a list of names into a string of the same names. */ char * -detract(np, ntype) - struct name *np; - int ntype; +detract(struct name *np, int ntype) { int s, comma; char *cp, *top; @@ -165,8 +158,7 @@ detract(np, ntype) * Throw away things between ()'s, and take anything between <>. */ char * -yankword(ap, wbuf) - char *ap, wbuf[]; +yankword(char *ap, char wbuf[]) { char *cp, *cp2; @@ -211,8 +203,7 @@ yankword(ap, wbuf) * and look for words before metacharacters %, @, !. */ char * -yanklogin(ap, wbuf) - char *ap, wbuf[]; +yanklogin(char *ap, char wbuf[]) { char *cp, *cp2, *cp_temp; int n; @@ -287,10 +278,7 @@ yanklogin(ap, wbuf) * program and removed. */ struct name * -outof(names, fo, hp) - struct name *names; - FILE *fo; - struct header *hp; +outof(struct name *names, FILE *fo, struct header *hp) { int c, ispipe; struct name *np, *top; @@ -440,8 +428,7 @@ cant: * be a filename. We cheat with .'s to allow path names like ./... */ int -isfileaddr(name) - char *name; +isfileaddr(char *name) { char *cp; @@ -464,8 +451,7 @@ isfileaddr(name) */ struct name * -usermap(names) - struct name *names; +usermap(struct name *names) { struct name *new, *np, *cp; struct grouphead *gh; @@ -499,10 +485,7 @@ usermap(names) */ struct name * -gexpand(nlist, gh, metoo, ntype) - struct name *nlist; - struct grouphead *gh; - int metoo, ntype; +gexpand(struct name *nlist, struct grouphead *gh, int metoo, int ntype) { struct group *gp; struct grouphead *ngh; @@ -546,8 +529,7 @@ skip: * Concatenate the two passed name lists, return the result. */ struct name * -cat(n1, n2) - struct name *n1, *n2; +cat(struct name *n1, struct name *n2) { struct name *tail; @@ -566,8 +548,7 @@ cat(n1, n2) * Return an error if the name list won't fit. */ char ** -unpack(np) - struct name *np; +unpack(struct name *np) { char **ap, **top; struct name *n; @@ -611,8 +592,7 @@ unpack(np) * Return the head of the new list. */ struct name * -elide(names) - struct name *names; +elide(struct name *names) { struct name *np, *t, *new; struct name *x; @@ -710,8 +690,7 @@ elide(names) * the list. */ struct name * -put(list, node) - struct name *list, *node; +put(struct name *list, struct name *node) { node->n_flink = list; node->n_blink = NULL; @@ -725,8 +704,7 @@ put(list, node) * a name list and return it. */ int -count(np) - struct name *np; +count(struct name *np) { int c; @@ -740,9 +718,7 @@ count(np) * Delete the given name from a namelist. */ struct name * -delname(np, name) - struct name *np; - char name[]; +delname(struct name *np, char name[]) { struct name *p; @@ -772,8 +748,7 @@ delname(np, name) /* void -prettyprint(name) - struct name *name; +prettyprint(struct name *name) { struct name *np; |