Discussion:
Bug of route command
Add Reply
Liwei Jiang
2017-08-04 11:40:02 UTC
Reply
Permalink
Raw Message
Although route command is still in unfinished status, I still give it a
try. And I find a bug.
The 217 line of the code,
if (!get_hostname(*argv, (struct sockaddr_in *) &rt->rt_gateway))
should be changed to
if (!get_hostname(*(++argv), (struct sockaddr_in *) &rt->rt_gateway))
This way, command like "route add default gw 192.168.137.1" can work now.
Loading...