mirror of
https://gitlab.nic.cz/labs/bird.git
synced 2025-01-03 15:41:54 +00:00
Socktest: check existence of given name of interface
This commit is contained in:
parent
856c3d105c
commit
43ae8c395f
@ -102,6 +102,11 @@ skt_parse_args(int argc, char *argv[], int is_send)
|
||||
case 'i':
|
||||
s->iface = if_get_by_name(optarg);
|
||||
s->iface->index = if_nametoindex(optarg);
|
||||
if (s->iface->index == 0)
|
||||
{
|
||||
printf("No interface exists with the name %s \n", optarg);
|
||||
exit(1);
|
||||
}
|
||||
break;
|
||||
case 'B':
|
||||
cf_bind = 1;
|
||||
|
Loading…
Reference in New Issue
Block a user