Skip to content

Commit

Permalink
fix bugs
Browse files Browse the repository at this point in the history
  • Loading branch information
liexusong committed Mar 22, 2017
1 parent 6849cb5 commit 0bece94
Showing 1 changed file with 8 additions and 10 deletions.
18 changes: 8 additions & 10 deletions beast.c
Original file line number Diff line number Diff line change
Expand Up @@ -1044,18 +1044,16 @@ static int validate_networkcard()
}

address = get_mac_address(networkcard_start);
if (!address) {
return -1;
if (address) {
for (ptr = allow_networkcards; *ptr; ptr++) {
if (!strcasecmp(address, *ptr)) {
free(address); /* release buffer */
return 0;
}
}
free(address);
}

for (ptr = allow_networkcards; *ptr; ptr++) {
if (!strcasecmp(address, *ptr)) {
free(address); /* release buffer */
return 0;
}
}
free(address);

if (endof_networkcard) {
break;
}
Expand Down

0 comments on commit 0bece94

Please sign in to comment.