summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/socket.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/socket.c b/src/socket.c
index 66907c8c..901b8cdf 100644
--- a/src/socket.c
+++ b/src/socket.c
@@ -169,6 +169,8 @@ int osmo_sockaddr_is_local(struct sockaddr *addr, socklen_t addrlen)
}
for (ifa = ifaddr; ifa != NULL; ifa = ifa->ifa_next) {
+ if (!ifa->ifa_addr)
+ continue;
if (sockaddr_equal(ifa->ifa_addr, addr, addrlen))
return 1;
}