ipaccess: Fix the case of specifying the interface
Pablo pointed out that my previous commit was rubish. If we have less than two arguments we want ifname to remain NULL and if we have a second argument (or more) we want to use that as the interface name to bind to.
This commit is contained in:
parent
c0370e4399
commit
1e9ae4be66
|
@ -175,6 +175,7 @@ int main(int argc, char **argv)
|
|||
if (argc < 2) {
|
||||
fprintf(stdout, "you might need to specify the outgoing\n"
|
||||
" network interface, e.g. ``%s eth0''\n", argv[0]);
|
||||
} else {
|
||||
ifname = argv[1];
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue