diff options
author | sobomax <sobomax@FreeBSD.org> | 2004-01-30 09:03:01 +0000 |
---|---|---|
committer | sobomax <sobomax@FreeBSD.org> | 2004-01-30 09:03:01 +0000 |
commit | 2b5008cb00729f95719898d4a9ea3dedef494d47 (patch) | |
tree | 3df42d90bb8eb699080d9bc3517350f8f51d76ea /sys/net | |
parent | 5dfe9e26eabfd080d82fd9209e3a289ac08b6fda (diff) | |
download | FreeBSD-src-2b5008cb00729f95719898d4a9ea3dedef494d47.zip FreeBSD-src-2b5008cb00729f95719898d4a9ea3dedef494d47.tar.gz |
Remove NetBSD'isms (add FreeBSD'isms?), which makes gre(4) working again.
Diffstat (limited to 'sys/net')
-rw-r--r-- | sys/net/if_gre.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/sys/net/if_gre.c b/sys/net/if_gre.c index aab7068..254d9a3 100644 --- a/sys/net/if_gre.c +++ b/sys/net/if_gre.c @@ -351,8 +351,7 @@ gre_output(struct ifnet *ifp, struct mbuf *m, struct sockaddr *dst, gh = mtod(m, struct greip *); if (sc->g_proto == IPPROTO_GRE) { /* we don't have any GRE flags for now */ - - memset((void *)&gh->gi_g, 0, sizeof(struct gre_h)); + memset((void *)gh, 0, sizeof(struct greip)); gh->gi_ptype = htons(etype); } @@ -364,7 +363,7 @@ gre_output(struct ifnet *ifp, struct mbuf *m, struct sockaddr *dst, ((struct ip*)gh)->ip_ttl = GRE_TTL; ((struct ip*)gh)->ip_tos = ip->ip_tos; ((struct ip*)gh)->ip_id = ip->ip_id; - gh->gi_len = htons(m->m_pkthdr.len); + gh->gi_len = m->m_pkthdr.len; } ifp->if_opackets++; |