Deleted Added
full compact
res_init.c (269867) res_init.c (288114)
1/*
2 * Copyright (c) 1985, 1989, 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

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

64 * OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
65 */
66
67#if defined(LIBC_SCCS) && !defined(lint)
68static const char sccsid[] = "@(#)res_init.c 8.1 (Berkeley) 6/7/93";
69static const char rcsid[] = "$Id: res_init.c,v 1.26 2008/12/11 09:59:00 marka Exp $";
70#endif /* LIBC_SCCS and not lint */
71#include <sys/cdefs.h>
1/*
2 * Copyright (c) 1985, 1989, 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

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

64 * OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
65 */
66
67#if defined(LIBC_SCCS) && !defined(lint)
68static const char sccsid[] = "@(#)res_init.c 8.1 (Berkeley) 6/7/93";
69static const char rcsid[] = "$Id: res_init.c,v 1.26 2008/12/11 09:59:00 marka Exp $";
70#endif /* LIBC_SCCS and not lint */
71#include <sys/cdefs.h>
72__FBSDID("$FreeBSD: head/lib/libc/resolv/res_init.c 269867 2014-08-12 12:36:06Z ume $");
72__FBSDID("$FreeBSD: head/lib/libc/resolv/res_init.c 288114 2015-09-22 15:57:26Z rodrigc $");
73
74#include "port_before.h"
75
76#include "namespace.h"
77
78#include <sys/types.h>
79#include <sys/param.h>
80#include <sys/socket.h>

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

713 while (*cp && *cp != ' ' && *cp != '\t')
714 cp++;
715 }
716}
717
718#ifdef RESOLVSORT
719/* XXX - should really support CIDR which means explicit masks always. */
720static u_int32_t
73
74#include "port_before.h"
75
76#include "namespace.h"
77
78#include <sys/types.h>
79#include <sys/param.h>
80#include <sys/socket.h>

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

713 while (*cp && *cp != ' ' && *cp != '\t')
714 cp++;
715 }
716}
717
718#ifdef RESOLVSORT
719/* XXX - should really support CIDR which means explicit masks always. */
720static u_int32_t
721net_mask(in) /*!< XXX - should really use system's version of this */
722 struct in_addr in;
721net_mask(struct in_addr in) /*!< XXX - should really use system's version of this */
723{
724 u_int32_t i = ntohl(in.s_addr);
725
726 if (IN_CLASSA(i))
727 return (htonl(IN_CLASSA_NET));
728 else if (IN_CLASSB(i))
729 return (htonl(IN_CLASSB_NET));
730 return (htonl(IN_CLASSC_NET));

--- 199 unchanged lines hidden ---
722{
723 u_int32_t i = ntohl(in.s_addr);
724
725 if (IN_CLASSA(i))
726 return (htonl(IN_CLASSA_NET));
727 else if (IN_CLASSB(i))
728 return (htonl(IN_CLASSB_NET));
729 return (htonl(IN_CLASSC_NET));

--- 199 unchanged lines hidden ---