diff options
author | tegge <tegge@FreeBSD.org> | 1997-05-19 01:28:39 +0000 |
---|---|---|
committer | tegge <tegge@FreeBSD.org> | 1997-05-19 01:28:39 +0000 |
commit | 4f2495eff057ea8a9f8c638ee404521f89177a51 (patch) | |
tree | 64d76c14b2d29f27d31f201bf752d1e56ef200df /sys/netinet | |
parent | cc4887cc106ed34893d4d94b14671a6862ffcc9a (diff) | |
download | FreeBSD-src-4f2495eff057ea8a9f8c638ee404521f89177a51.zip FreeBSD-src-4f2495eff057ea8a9f8c638ee404521f89177a51.tar.gz |
Break apart initialization of s and inp from the declarations in
in_setsockaddr and in_setpeeraddr.
Suggested by: Justin T. Gibbs <gibbs@plutotech.com>
Diffstat (limited to 'sys/netinet')
-rw-r--r-- | sys/netinet/in_pcb.c | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/sys/netinet/in_pcb.c b/sys/netinet/in_pcb.c index 4527e28..95409fc 100644 --- a/sys/netinet/in_pcb.c +++ b/sys/netinet/in_pcb.c @@ -31,7 +31,7 @@ * SUCH DAMAGE. * * @(#)in_pcb.c 8.4 (Berkeley) 5/24/95 - * $Id: in_pcb.c,v 1.31 1997/04/27 20:01:04 wollman Exp $ + * $Id: in_pcb.c,v 1.32 1997/05/19 00:18:30 tegge Exp $ */ #include <sys/param.h> @@ -470,10 +470,12 @@ in_setsockaddr(so, nam) struct socket *so; struct mbuf *nam; { - int s = splnet(); - register struct inpcb *inp = sotoinpcb(so); + int s; + register struct inpcb *inp; register struct sockaddr_in *sin; + s = splnet(); + inp = sotoinpcb(so); if (!inp) { splx(s); return EINVAL; @@ -494,10 +496,12 @@ in_setpeeraddr(so, nam) struct socket *so; struct mbuf *nam; { - int s = splnet(); - struct inpcb *inp = sotoinpcb(so); + int s; + struct inpcb *inp; register struct sockaddr_in *sin; + s = splnet(); + inp = sotoinpcb(so); if (!inp) { splx(s); return EINVAL; |