diff options
| author | Julian Elischer <julian@FreeBSD.org> | 2001-09-07 07:19:12 +0000 |
|---|---|---|
| committer | Julian Elischer <julian@FreeBSD.org> | 2001-09-07 07:19:12 +0000 |
| commit | ff265614c166724356a66c341ff3bb9c4ee3c260 (patch) | |
| tree | d013f55450d9cf7688fbd35f24d13797e19ae112 /sys/netinet6/ah_input.c | |
| parent | f97e0a071943145b1545078f207b0aa628c402eb (diff) | |
Notes
Diffstat (limited to 'sys/netinet6/ah_input.c')
| -rw-r--r-- | sys/netinet6/ah_input.c | 18 |
1 files changed, 5 insertions, 13 deletions
diff --git a/sys/netinet6/ah_input.c b/sys/netinet6/ah_input.c index 4ee2a994c5f0..63605d036f4e 100644 --- a/sys/netinet6/ah_input.c +++ b/sys/netinet6/ah_input.c @@ -97,13 +97,9 @@ extern struct protosw inetsw[]; void -#if __STDC__ -ah4_input(struct mbuf *m, ...) -#else -ah4_input(m, va_alist) +ah4_input(m, off) struct mbuf *m; - va_dcl -#endif + int off; { struct ip *ip; struct ah *ah; @@ -115,15 +111,9 @@ ah4_input(m, va_alist) struct secasvar *sav = NULL; u_int16_t nxt; size_t hlen; - int off, proto; - va_list ap; + int proto; size_t stripsiz = 0; - va_start(ap, m); - off = va_arg(ap, int); - proto = mtod(m, struct ip *)->ip_p; - va_end(ap); - #ifndef PULLDOWN_TEST if (m->m_len < off + sizeof(struct newah)) { m = m_pullup(m, off + sizeof(struct newah)); @@ -136,9 +126,11 @@ ah4_input(m, va_alist) } ip = mtod(m, struct ip *); + proto = ip->ip_p; ah = (struct ah *)(((caddr_t)ip) + off); #else ip = mtod(m, struct ip *); + proto = ip->ip_p; IP6_EXTHDR_GET(ah, struct ah *, m, off, sizeof(struct newah)); if (ah == NULL) { ipseclog((LOG_DEBUG, "IPv4 AH input: can't pullup;" |
