Deleted Added
full compact
raw_cb.c (108107) raw_cb.c (109623)
1/*
2 * Copyright (c) 1980, 1986, 1993
3 * The Regents of the University of California. All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

--- 17 unchanged lines hidden (view full) ---

26 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
27 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
28 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
29 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
30 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
31 * SUCH DAMAGE.
32 *
33 * @(#)raw_cb.c 8.1 (Berkeley) 6/10/93
1/*
2 * Copyright (c) 1980, 1986, 1993
3 * The Regents of the University of California. All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

--- 17 unchanged lines hidden (view full) ---

26 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
27 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
28 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
29 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
30 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
31 * SUCH DAMAGE.
32 *
33 * @(#)raw_cb.c 8.1 (Berkeley) 6/10/93
34 * $FreeBSD: head/sys/net/raw_cb.c 108107 2002-12-19 22:58:27Z bmilekic $
34 * $FreeBSD: head/sys/net/raw_cb.c 109623 2003-01-21 08:56:16Z alfred $
35 */
36
37#include <sys/param.h>
38#include <sys/domain.h>
39#include <sys/malloc.h>
40#include <sys/protosw.h>
41#include <sys/socket.h>
42#include <sys/socketvar.h>

--- 91 unchanged lines hidden (view full) ---

134 struct mbuf *nam;
135{
136 struct sockaddr *addr = mtod(nam, struct sockaddr *);
137 register struct rawcb *rp;
138
139 if (ifnet == 0)
140 return (EADDRNOTAVAIL);
141 rp = sotorawcb(so);
35 */
36
37#include <sys/param.h>
38#include <sys/domain.h>
39#include <sys/malloc.h>
40#include <sys/protosw.h>
41#include <sys/socket.h>
42#include <sys/socketvar.h>

--- 91 unchanged lines hidden (view full) ---

134 struct mbuf *nam;
135{
136 struct sockaddr *addr = mtod(nam, struct sockaddr *);
137 register struct rawcb *rp;
138
139 if (ifnet == 0)
140 return (EADDRNOTAVAIL);
141 rp = sotorawcb(so);
142 nam = m_copym(nam, 0, M_COPYALL, M_TRYWAIT);
142 nam = m_copym(nam, 0, M_COPYALL, 0);
143 rp->rcb_laddr = mtod(nam, struct sockaddr *);
144 return (0);
145}
146#endif
143 rp->rcb_laddr = mtod(nam, struct sockaddr *);
144 return (0);
145}
146#endif