summaryrefslogtreecommitdiffstats
path: root/sysdep/unix
diff options
context:
space:
mode:
Diffstat (limited to 'sysdep/unix')
-rw-r--r--sysdep/unix/krt-iface.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sysdep/unix/krt-iface.c b/sysdep/unix/krt-iface.c
index 6303558..083af29 100644
--- a/sysdep/unix/krt-iface.c
+++ b/sysdep/unix/krt-iface.c
@@ -147,7 +147,7 @@ krt_if_scan(struct kif_proto *p)
res = ioctl(if_scan_sock, SIOCGIFCONF, &ic);
if (res < 0 && errno != EFAULT)
die("SIOCCGIFCONF: %m");
- if (res < last_ifbuf_size)
+ if (res >= 0 && ic.ifc_len < last_ifbuf_size)
{
scan_ifs(r, ic.ifc_len);
break;