if (dumpstats) { wi_dumpstats(iface); exit(0); }
int main(argc, argv)	int			argc;	char			*argv[];{	char			*iface = NULL;	int                     ch, p, dumpstats = 0;	if (argc > 1 && argv[1][0] != '-') {		iface = argv[1];		memcpy(&argv[1], &argv[2], argc * sizeof(char *));		argc--;	}	while((ch = getopt(argc, argv,	    "hoc:d:f:p:r:q:t:n:s:i:m:P:S:T:e:k:v:")) != -1) {	        for (p = 0; ch && wi_opt[p].key; p++)		        if (ch == wi_opt[p].key) {			        wi_opt[p].optarg = optarg;				if (ch == 'T')	/* key 1-4/0-3 kludge */				        (*optarg)--;				ch = 0;			}		switch(ch) {		case 0:		        break;		case 'o':			dumpstats ++;			break;		case 'i':		        if (iface == NULL)			        iface = optarg;			break;		case 'v': 		        for (p = 0; wi_opt[p].key; p++)			        if (wi_opt[p].key == 'k') {				        wi_opt[p].wi_code = strtol(optarg, 								   NULL, 10);					wi_opt[p].wi_code--; /* 1-4/0-3 */					break;				}		       	break;		case 'h':		default:		        usage(argv[0]);			break;		}	}	if (iface == NULL)		usage(argv[0]);	if (dumpstats) {	        wi_dumpstats(iface);		exit(0);	}	for (p = 0; wi_opt[p].key; p++)	        if (wi_opt[p].optarg != NULL)		        wi_opt[p].function(iface, wi_opt[p].wi_code, 					   wi_opt[p].optarg);	wi_dumpinfo(iface);	exit(0);}