]> git.saurik.com Git - apple/xnu.git/blobdiff - bsd/netinet/ip_input.c
xnu-792.2.4.tar.gz
[apple/xnu.git] / bsd / netinet / ip_input.c
index 4a219f43cc461353de3056b76722c93c1ca76e6f..89f607747655b1e15cb41b0d86adf810e1522719 100644 (file)
@@ -1678,7 +1678,7 @@ nosourcerouting:
                         * locate outgoing interface; if we're the destination,
                         * use the incoming interface (should be same).
                         */
-                       if ((ia = (INA)ifa_ifwithaddr((SA)&ipaddr)) != 0) {
+                       if ((ia = (INA)ifa_ifwithaddr((SA)&ipaddr)) == 0) {
                                if ((ia = ip_rtaddr(ipaddr.sin_addr, ipforward_rt)) == 0) {
                                        type = ICMP_UNREACH;
                                        code = ICMP_UNREACH_HOST;