From: Simon Schubert Date: Thu, 3 Jul 2008 08:22:36 +0000 (+0000) Subject: Make ip_forward public, so that it can be used from other places as well. X-Git-Tag: v2.0.1~239 X-Git-Url: https://gitweb.dragonflybsd.org/dragonfly.git/commitdiff_plain/33cc7bb127982b7b61d5cb4a93754fd65466cd2e Make ip_forward public, so that it can be used from other places as well. Ok'ed: sephe@ --- diff --git a/sys/netinet/in_var.h b/sys/netinet/in_var.h index 0be0c04845..96b0091d04 100644 --- a/sys/netinet/in_var.h +++ b/sys/netinet/in_var.h @@ -32,7 +32,7 @@ * * @(#)in_var.h 8.2 (Berkeley) 1/9/95 * $FreeBSD: src/sys/netinet/in_var.h,v 1.33.2.3 2001/12/14 20:09:34 jlemon Exp $ - * $DragonFly: src/sys/netinet/in_var.h,v 1.13 2008/06/09 11:24:24 sephe Exp $ + * $DragonFly: src/sys/netinet/in_var.h,v 1.14 2008/07/03 08:22:36 corecode Exp $ */ #ifndef _NETINET_IN_VAR_H_ @@ -247,6 +247,7 @@ int in_control (struct socket *, u_long, caddr_t, struct ifnet *, struct thread *); void in_rtqdrain (void); void ip_input (struct mbuf *); +void ip_forward (struct mbuf *, boolean_t, struct sockaddr_in *); int in_ifadown (struct ifaddr *ifa, int); void in_ifscrub (struct ifnet *, struct in_ifaddr *); void in_iaunlink (struct in_ifaddr *); diff --git a/sys/netinet/ip_input.c b/sys/netinet/ip_input.c index beda59d387..0ffdf367e9 100644 --- a/sys/netinet/ip_input.c +++ b/sys/netinet/ip_input.c @@ -65,7 +65,7 @@ * * @(#)ip_input.c 8.2 (Berkeley) 1/4/94 * $FreeBSD: src/sys/netinet/ip_input.c,v 1.130.2.52 2003/03/07 07:01:28 silby Exp $ - * $DragonFly: src/sys/netinet/ip_input.c,v 1.81 2008/06/09 11:24:24 sephe Exp $ + * $DragonFly: src/sys/netinet/ip_input.c,v 1.82 2008/07/03 08:22:36 corecode Exp $ */ #define _IP_VHL @@ -293,8 +293,6 @@ static struct malloc_pipe ipq_mpipe; static void save_rte (u_char *, struct in_addr); static int ip_dooptions (struct mbuf *m, int, struct sockaddr_in *next_hop); -static void ip_forward (struct mbuf *m, boolean_t using_srcrt, - struct sockaddr_in *next_hop); static void ip_freef (struct ipq *); static void ip_input_handler (struct netmsg *); static struct mbuf *ip_reass (struct mbuf *, struct ipq *, @@ -1876,7 +1874,7 @@ u_char inetctlerrmap[PRC_NCMDS] = { * The using_srcrt parameter indicates whether the packet is being forwarded * via a source route. */ -static void +void ip_forward(struct mbuf *m, boolean_t using_srcrt, struct sockaddr_in *next_hop) { struct ip *ip = mtod(m, struct ip *);