=================================================================== RCS file: /cvsrepo/anoncvs/cvs/src/usr.bin/sudo/Attic/interfaces.c,v retrieving revision 1.4 retrieving revision 1.5 diff -c -r1.4 -r1.5 *** src/usr.bin/sudo/Attic/interfaces.c 2003/03/15 21:23:54 1.4 --- src/usr.bin/sudo/Attic/interfaces.c 2003/04/03 19:15:34 1.5 *************** *** 73,85 **** #ifdef HAVE_UNISTD_H # include #endif /* HAVE_UNISTD_H */ #include - #include #ifdef _ISC # include # include # include - # include # define STRSET(cmd, param, len) {strioctl.ic_cmd=(cmd);\ strioctl.ic_dp=(param);\ strioctl.ic_timout=0;\ --- 73,88 ---- #ifdef HAVE_UNISTD_H # include #endif /* HAVE_UNISTD_H */ + #ifdef HAVE_ERR_H + # include + #else + # include "emul/err.h" + #endif /* HAVE_ERR_H */ #include #ifdef _ISC # include # include # include # define STRSET(cmd, param, len) {strioctl.ic_cmd=(cmd);\ strioctl.ic_dp=(param);\ strioctl.ic_timout=0;\ *************** *** 99,105 **** #include "interfaces.h" #ifndef lint ! static const char rcsid[] = "$Sudo: interfaces.c,v 1.68 2003/03/15 20:31:02 millert Exp $"; #endif /* lint */ --- 102,108 ---- #include "interfaces.h" #ifndef lint ! static const char rcsid[] = "$Sudo: interfaces.c,v 1.69 2003/04/02 18:25:19 millert Exp $"; #endif /* lint */ *************** *** 186,196 **** #endif /* _ISC */ sock = socket(AF_INET, SOCK_DGRAM, 0); ! if (sock < 0) { ! (void) fprintf(stderr, "%s: cannot open socket: %s\n", ! Argv[0], strerror(errno)); ! exit(1); ! } /* * Get interface configuration or return (leaving num_interfaces == 0) --- 189,196 ---- #endif /* _ISC */ sock = socket(AF_INET, SOCK_DGRAM, 0); ! if (sock < 0) ! err(1, "cannot open socket"); /* * Get interface configuration or return (leaving num_interfaces == 0) *************** *** 324,328 **** puts("Local IP address and netmask pairs:"); for (i = 0; i < num_interfaces; i++) printf("\t%s / 0x%x\n", inet_ntoa(interfaces[i].addr), ! ntohl(interfaces[i].netmask.s_addr)); } --- 324,328 ---- puts("Local IP address and netmask pairs:"); for (i = 0; i < num_interfaces; i++) printf("\t%s / 0x%x\n", inet_ntoa(interfaces[i].addr), ! (unsigned int)ntohl(interfaces[i].netmask.s_addr)); }