Deleted Added
full compact
in.h (165648) in.h (166368)
1/*-
2 * Copyright (c) 1982, 1986, 1990, 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

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

22 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
23 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
24 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
25 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
26 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
27 * SUCH DAMAGE.
28 *
29 * @(#)in.h 8.3 (Berkeley) 1/3/94
1/*-
2 * Copyright (c) 1982, 1986, 1990, 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

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

22 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
23 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
24 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
25 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
26 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
27 * SUCH DAMAGE.
28 *
29 * @(#)in.h 8.3 (Berkeley) 1/3/94
30 * $FreeBSD: head/sys/netinet/in.h 165648 2006-12-29 21:59:17Z piso $
30 * $FreeBSD: head/sys/netinet/in.h 166368 2007-01-31 14:34:47Z bms $
31 */
32
33#ifndef _NETINET_IN_H_
34#define _NETINET_IN_H_
35
36#include <sys/cdefs.h>
37#include <sys/_types.h>
38#include <machine/endian.h>

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

346#define IN_CLASSD_NET 0xf0000000 /* These ones aren't really */
347#define IN_CLASSD_NSHIFT 28 /* net and host fields, but */
348#define IN_CLASSD_HOST 0x0fffffff /* routing needn't know. */
349#define IN_MULTICAST(i) IN_CLASSD(i)
350
351#define IN_EXPERIMENTAL(i) (((u_int32_t)(i) & 0xf0000000) == 0xf0000000)
352#define IN_BADCLASS(i) (((u_int32_t)(i) & 0xf0000000) == 0xf0000000)
353
31 */
32
33#ifndef _NETINET_IN_H_
34#define _NETINET_IN_H_
35
36#include <sys/cdefs.h>
37#include <sys/_types.h>
38#include <machine/endian.h>

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

346#define IN_CLASSD_NET 0xf0000000 /* These ones aren't really */
347#define IN_CLASSD_NSHIFT 28 /* net and host fields, but */
348#define IN_CLASSD_HOST 0x0fffffff /* routing needn't know. */
349#define IN_MULTICAST(i) IN_CLASSD(i)
350
351#define IN_EXPERIMENTAL(i) (((u_int32_t)(i) & 0xf0000000) == 0xf0000000)
352#define IN_BADCLASS(i) (((u_int32_t)(i) & 0xf0000000) == 0xf0000000)
353
354#define IN_LINKLOCAL(i) (((u_int32_t)(i) & 0xffff0000) == 0xa9fe0000)
355
356#define IN_PRIVATE(i) ((((u_int32_t)(i) & 0xff000000) == 0x0a000000) || \
357 (((u_int32_t)(i) & 0xfff00000) == 0xac100000) || \
358 (((u_int32_t)(i) & 0xffff0000) == 0xc0a80000))
359
360#define IN_LOCAL_GROUP(i) (((u_int32_t)(i) & 0xffffff00) == 0xe0000000)
361
362#define IN_ANY_LOCAL(i) (IN_LINKLOCAL(i) || IN_LOCAL_GROUP(i))
363
354#define INADDR_LOOPBACK (u_int32_t)0x7f000001
355#ifndef _KERNEL
356#define INADDR_NONE 0xffffffff /* -1 return */
357#endif
358
359#define INADDR_UNSPEC_GROUP (u_int32_t)0xe0000000 /* 224.0.0.0 */
360#define INADDR_ALLHOSTS_GROUP (u_int32_t)0xe0000001 /* 224.0.0.1 */
361#define INADDR_ALLRTRS_GROUP (u_int32_t)0xe0000002 /* 224.0.0.2 */

--- 246 unchanged lines hidden ---
364#define INADDR_LOOPBACK (u_int32_t)0x7f000001
365#ifndef _KERNEL
366#define INADDR_NONE 0xffffffff /* -1 return */
367#endif
368
369#define INADDR_UNSPEC_GROUP (u_int32_t)0xe0000000 /* 224.0.0.0 */
370#define INADDR_ALLHOSTS_GROUP (u_int32_t)0xe0000001 /* 224.0.0.1 */
371#define INADDR_ALLRTRS_GROUP (u_int32_t)0xe0000002 /* 224.0.0.2 */

--- 246 unchanged lines hidden ---