mirror of
https://github.com/ep00ch/lwip-contrib-mac.git
synced 2024-06-12 01:29:28 +00:00
Fix adapter range detection (last adapter could not be used)
This commit is contained in:
parent
e4442f02da
commit
77ab1cb406
|
@ -171,7 +171,7 @@ init_adapter(int adapter_num, char *mac_addr, input_fn input, void *arg)
|
|||
return NULL;
|
||||
}
|
||||
/* adapter index out of range */
|
||||
if (adapter_num > AdapterNum) {
|
||||
if (adapter_num >= AdapterNum) {
|
||||
printf("Invalid adapter_num: %d\n", adapter_num);
|
||||
free(pa);
|
||||
return NULL;
|
||||
|
|
Loading…
Reference in New Issue
Block a user