don't leak malloced variables in the loop; remove double alloc
Signed-off-by: Alexey Fomenko <ext-alexey.fomenko@nokia.com> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
This commit is contained in:
committed by
Denys Vlasenko
parent
940c7206c2
commit
1df0af7670
@@ -156,7 +156,7 @@ int nameif_main(int argc, char **argv)
|
||||
|
||||
if (argc) {
|
||||
while (*argv) {
|
||||
char *ifname = xstrdup(*argv++);
|
||||
char *ifname = *argv++;
|
||||
prepend_new_eth_table(&clist, ifname, *argv++);
|
||||
}
|
||||
} else {
|
||||
|
Reference in New Issue
Block a user