/* 1949, Wed 16 Feb 00 IF_LIST.C: Print a list of the WinDUmp-capable network interfaces Copyright (C) 2000-2002 by Nevil Brownlee, CAIDA | University of Auckland */ #include #include /* Globals in pcap-cygwd.c (This is a utility for NeTraMet users, I don't see it as part of the libpcap library!) */ int find_interfaces(void); extern char *if_names[]; extern int cyg_interfaces; int main(int argc, char *argv[]) { int j; if (!find_interfaces()) { printf("Can't find any Packet Adapters\n"); exit(11); } printf("%d interfaces:\n", cyg_interfaces); for (j = 0; j != cyg_interfaces; ++j) printf(" %d %s\n", j, if_names[j]); }