summaryrefslogtreecommitdiffstats
path: root/net/net.c
diff options
context:
space:
mode:
Diffstat (limited to 'net/net.c')
-rw-r--r--net/net.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/net/net.c b/net/net.c
index 35781188c0..84168613f2 100644
--- a/net/net.c
+++ b/net/net.c
@@ -136,7 +136,8 @@ IPaddr_t getenv_ip(const char *name)
if (!var)
return 0;
- string_to_ip(var, &ip);
+ if (string_to_ip(var, &ip))
+ return 0;
return ip;
}