]> git.puffer.fish Git - mirror/frr.git/commit
lib: do not convert ip prefixes without '.' 3389/head
authorPhilippe Guibert <philippe.guibert@6wind.com>
Wed, 28 Nov 2018 11:15:09 +0000 (12:15 +0100)
committerPhilippe Guibert <philippe.guibert@6wind.com>
Wed, 28 Nov 2018 16:37:24 +0000 (17:37 +0100)
commit8d92004979dc68a6fcfb2bb8ee32f374088490da
tree3587b9fb757cdbc2602683ebd7292078727fe5dd
parent6c241117f87ca07afbae23a03c3a7ca59b1fce78
lib: do not convert ip prefixes without '.'

There are cases where the passed parameter for a vty command is either
an interface name or an ip address. Because the interface name can be a
number, and because the user may want to use a number to define an IP (
for instance 'ping 0' is valid from shell purpose), there is a choice
that needs to be done at frr level. either from the application point of
view, the interface name will be priorized, or each number will be
considered as an ip address. In that commit, the inet_aton procedure is
replaced with the inet_pton procedure that ignores ips with just a
number.

Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
lib/prefix.c