Deleted Added
full compact
2c2
< * Copyright (c) 1990, 1991, 1992, 1993, 1994, 1995, 1996
---
> * Copyright (c) 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997
26c26
< "@(#) $Header: addrtoname.c,v 1.54 96/12/05 22:10:19 leres Exp $ (LBL)";
---
> "@(#) $Header: addrtoname.c,v 1.61 97/06/15 13:20:18 leres Exp $ (LBL)";
47a48,53
> #ifdef HAVE_MALLOC_H
> #include <malloc.h>
> #endif
> #ifdef HAVE_MEMORY_H
> #include <memory.h>
> #endif
56a63,64
> #include "savestr.h"
> #include "setsignal.h"
211,215c219,223
< * (2) Address is foreign and -f was given. If -f was not
< * present, f_netmask and f_local are 0 and the second
< * test will succeed.
< * (3) The host portion is not 0 (i.e., a network address).
< * (4) The host portion is not broadcast.
---
> * (2) Address is foreign and -f was given. (If -f was not
> * give, f_netmask and f_local are 0 and the test
> * evaluates to true)
> * (3) -a was given or the host portion is not all ones
> * nor all zeros (i.e. not a network or broadcast address)
217,218c225,228
< if (!nflag && (addr & f_netmask) == f_localnet
< && (addr &~ netmask) != 0 && (addr | netmask) != 0xffffffff) {
---
> if (!nflag &&
> (addr & f_netmask) == f_localnet &&
> (aflag ||
> !((addr & ~netmask) == 0 || (addr | netmask) == 0xffffffff))) {
220c230
< (void)signal(SIGALRM, nohostname);
---
> (void)setsignal(SIGALRM, nohostname);
310c320
< memcpy(tp->e_nsap, nsap, nlen + 1);
---
> memcpy((char *)tp->e_nsap, (char *)nsap, nlen + 1);
700c710
< init_addrtoname(int fflag, u_int32_t localnet, u_int32_t mask)
---
> init_addrtoname(u_int32_t localnet, u_int32_t mask)