diff options
author | jilles <jilles@FreeBSD.org> | 2012-11-11 15:13:24 +0000 |
---|---|---|
committer | jilles <jilles@FreeBSD.org> | 2012-11-11 15:13:24 +0000 |
commit | be4aea389c2ee2935d4da915a8adff3184296095 (patch) | |
tree | fcf3f6690c167a8dd95717a0dc7e850cf9adfe63 /bin/sh/input.c | |
parent | 551d372a1bddcd79984b86718d69d54076349901 (diff) | |
download | FreeBSD-src-be4aea389c2ee2935d4da915a8adff3184296095.zip FreeBSD-src-be4aea389c2ee2935d4da915a8adff3184296095.tar.gz |
sh: Forward-declare struct alias instead of giving up type safety via void *
Diffstat (limited to 'bin/sh/input.c')
-rw-r--r-- | bin/sh/input.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/bin/sh/input.c b/bin/sh/input.c index 12f285f..b1f0475 100644 --- a/bin/sh/input.c +++ b/bin/sh/input.c @@ -350,7 +350,7 @@ pungetc(void) * We handle aliases this way. */ void -pushstring(char *s, int len, void *ap) +pushstring(char *s, int len, struct alias *ap) { struct strpush *sp; @@ -365,9 +365,9 @@ pushstring(char *s, int len, void *ap) sp->prevstring = parsenextc; sp->prevnleft = parsenleft; sp->prevlleft = parselleft; - sp->ap = (struct alias *)ap; + sp->ap = ap; if (ap) - ((struct alias *)ap)->flag |= ALIASINUSE; + ap->flag |= ALIASINUSE; parsenextc = s; parsenleft = len; INTON; |