]> jfr.im git - solanum.git/commitdiff
Fix a crash with testline, introduced with the "underlying ipv4" feature.
authorJilles Tjoelker <redacted>
Mon, 15 Oct 2012 00:08:22 +0000 (02:08 +0200)
committerJilles Tjoelker <redacted>
Mon, 15 Oct 2012 00:09:07 +0000 (02:09 +0200)
src/hostmask.c

index 99899af55b2c737ba78c8787b7e01ac8df9b1258..fb28bbbb5d3ec7e4f1ae4f5c4ce9a0900fbd47f0 100644 (file)
@@ -422,7 +422,7 @@ find_address_conf(const char *host, const char *sockhost, const char *user,
        }
 
 #ifdef RB_IPV6
-       if(ip->sa_family == AF_INET6 &&
+       if(ip != NULL && ip->sa_family == AF_INET6 &&
                        ipv4_from_ipv6((const struct sockaddr_in6 *)(const void *)ip, &ip4))
        {
                kconf = find_conf_by_address(NULL, NULL, NULL, (struct sockaddr *)&ip4, CONF_KILL, AF_INET, vuser, NULL);