diff --git a/bin/ethdump/ethdump.c b/bin/ethdump/ethdump.c index 7817da8..ec4767c 100644 --- a/bin/ethdump/ethdump.c +++ b/bin/ethdump/ethdump.c @@ -1,12 +1,14 @@ #include +#include + #include #include #include #include -static int nicNo = 1; +static int nicNo = 0; static char buf[4096]; static MBuf mbuf; @@ -61,6 +63,10 @@ main(int argc, const char *argv[]) printf("Ethernet Dump Tool\n"); + if (argc == 2) { + nicNo = atoi(argv[1]); + } + status = OSNICStat(nicNo, &nic); if (status == ENOENT) { printf("nic%d not present\n", nicNo);