|
Lines 134-139
Link Here
|
| 134 |
|
134 |
|
| 135 |
struct afswtch; |
135 |
struct afswtch; |
| 136 |
|
136 |
|
|
|
137 |
int supmedia = 0; |
| 138 |
|
| 137 |
#ifdef INET6 |
139 |
#ifdef INET6 |
| 138 |
char addr_buf[MAXHOSTNAMELEN *2 + 1]; /*for getnameinfo()*/ |
140 |
char addr_buf[MAXHOSTNAMELEN *2 + 1]; /*for getnameinfo()*/ |
| 139 |
#endif |
141 |
#endif |
|
Lines 351-366
Link Here
|
| 351 |
fprintf(stderr, "%s\n%s\n%s\n%s\n%s\n", |
353 |
fprintf(stderr, "%s\n%s\n%s\n%s\n%s\n", |
| 352 |
"usage: ifconfig interface address_family [address [dest_address]]", |
354 |
"usage: ifconfig interface address_family [address [dest_address]]", |
| 353 |
" [parameters]", |
355 |
" [parameters]", |
| 354 |
" ifconfig -a [-d] [-u] [address_family]", |
356 |
" ifconfig -a [-d] [-m] [-u] [address_family]", |
| 355 |
" ifconfig -l [-d] [-u] [address_family]", |
357 |
" ifconfig -l [-d] [-u] [address_family]", |
| 356 |
" ifconfig [-d] [-u]"); |
358 |
" ifconfig [-d] [-m] [-u]"); |
| 357 |
#else |
359 |
#else |
| 358 |
fprintf(stderr, "%s\n%s\n%s\n%s\n%s\n", |
360 |
fprintf(stderr, "%s\n%s\n%s\n%s\n%s\n", |
| 359 |
"usage: ifconfig [-L] interface address_family [address [dest_address]]", |
361 |
"usage: ifconfig [-L] interface address_family [address [dest_address]]", |
| 360 |
" [parameters]", |
362 |
" [parameters]", |
| 361 |
" ifconfig -a [-L] [-d] [-u] [address_family]", |
363 |
" ifconfig -a [-L] [-d] [-m] [-u] [address_family]", |
| 362 |
" ifconfig -l [-d] [-u] [address_family]", |
364 |
" ifconfig -l [-d] [-u] [address_family]", |
| 363 |
" ifconfig [-L] [-d] [-u]"); |
365 |
" ifconfig [-L] [-d] [-m] [-u]"); |
| 364 |
#endif |
366 |
#endif |
| 365 |
exit(1); |
367 |
exit(1); |
| 366 |
} |
368 |
} |
|
Lines 410-416
Link Here
|
| 410 |
uponly++; |
412 |
uponly++; |
| 411 |
break; |
413 |
break; |
| 412 |
case 'm': /* show media choices in status */ |
414 |
case 'm': /* show media choices in status */ |
| 413 |
/* ignored for compatibility */ |
415 |
supmedia = 1; |
| 414 |
break; |
416 |
break; |
| 415 |
default: |
417 |
default: |
| 416 |
usage(); |
418 |
usage(); |
|
Lines 421-427
Link Here
|
| 421 |
argv += optind; |
423 |
argv += optind; |
| 422 |
|
424 |
|
| 423 |
/* -l cannot be used with -a or -m */ |
425 |
/* -l cannot be used with -a or -m */ |
| 424 |
if (namesonly && all) |
426 |
if (namesonly && (all || supmedia)) |
| 425 |
usage(); |
427 |
usage(); |
| 426 |
|
428 |
|
| 427 |
/* nonsense.. */ |
429 |
/* nonsense.. */ |