"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "common/inet.c" between
dhcp-4.3.6-P1.tar.gz and dhcp-4.4.1.tar.gz

About: ISC DHCP implements the "Dynamic Host Configuration Protocols" for connection to a local network. 4.4.x release series.

inet.c  (dhcp-4.3.6-P1):inet.c  (dhcp-4.4.1)
/* inet.c /* inet.c
Subroutines to manipulate internet addresses and ports in a safely portable Subroutines to manipulate internet addresses and ports in a safely portable
way... */ way... */
/* /*
* Copyright (c) 2004-2016 by Internet Systems Consortium, Inc. ("ISC") * Copyright (c) 2004-2017 by Internet Systems Consortium, Inc. ("ISC")
* Copyright (c) 1995-2003 by Internet Software Consortium * Copyright (c) 1995-2003 by Internet Software Consortium
* *
* Permission to use, copy, modify, and distribute this software for any * This Source Code Form is subject to the terms of the Mozilla Public
* purpose with or without fee is hereby granted, provided that the above * License, v. 2.0. If a copy of the MPL was not distributed with this
* copyright notice and this permission notice appear in all copies. * file, You can obtain one at http://mozilla.org/MPL/2.0/.
* *
* THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES
* WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
* MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR
* ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
* WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
* ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT
* OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
* *
* Internet Systems Consortium, Inc. * Internet Systems Consortium, Inc.
skipping to change at line 649 skipping to change at line 649
if ((*endptr != '\0') || (errno == ERANGE) || (errno == EINVAL)) if ((*endptr != '\0') || (errno == ERANGE) || (errno == EINVAL))
log_fatal ("Invalid port pair specification: %s", port); log_fatal ("Invalid port pair specification: %s", port);
if (local_port < lower || local_port > upper) if (local_port < lower || local_port > upper)
log_fatal("Port pair specified is out of range (%ld-%ld).", log_fatal("Port pair specified is out of range (%ld-%ld).",
lower, upper); lower, upper);
return htons((u_int16_t)local_port); return htons((u_int16_t)local_port);
} }
#ifdef DHCPv6
/* Print a v6 address from an in6_addr struct */
const char *
pin6_addr(const struct in6_addr *src){
if (!src) {
return ("<null>");
}
struct iaddr addr;
addr.len = 16;
memcpy(addr.iabuf, src->s6_addr, 16);
return (piaddr(addr));
}
#endif
 End of changes. 3 change blocks. 
4 lines changed or deleted 4 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)