From: Heinrich Schuchardt Date: Thu, 5 Dec 2024 19:32:53 +0000 (+0100) Subject: net: lwip: do not return CMD_RET_USAGE if no interface X-Git-Url: http://git.dujemihanovic.xyz/img/%7B%7B%20%28.OutputFormats.Get?a=commitdiff_plain;h=b6691d0add999459393a19f0f02b66243ee2a4ae;p=u-boot.git 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 Reviewed-by: Jerome Forissier --- diff --git a/net/lwip/dns.c b/net/lwip/dns.c index 4b937feaee..1de63c9998 100644 --- a/net/lwip/dns.c +++ b/net/lwip/dns.c @@ -56,7 +56,7 @@ static int dns_loop(struct udevice *udev, const char *name, const char *var) netif = net_lwip_new_netif(udev); if (!netif) - return -1; + return CMD_RET_FAILURE; dns_init();