net: lwip: do not return CMD_RET_USAGE if no interface
If the dns command cannot find a network interface, we should return CMD_RETFAIURE and not -1 (CMD_RET_USAGE). Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com> Reviewed-by: Jerome Forissier <jerome.forissier@linaro.org>
This commit is contained in:

committed by
Tom Rini

parent
9378307136
commit
b6691d0add
@@ -56,7 +56,7 @@ static int dns_loop(struct udevice *udev, const char *name, const char *var)
|
|||||||
|
|
||||||
netif = net_lwip_new_netif(udev);
|
netif = net_lwip_new_netif(udev);
|
||||||
if (!netif)
|
if (!netif)
|
||||||
return -1;
|
return CMD_RET_FAILURE;
|
||||||
|
|
||||||
dns_init();
|
dns_init();
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user