From 31f44b278dba5869169403cbaa6b995ecbabfee7 Mon Sep 17 00:00:00 2001 From: ae Date: Mon, 15 Oct 2018 10:25:34 +0000 Subject: [PATCH] Add extra parentheses to fix "versrcreach" opcode, (oif != NULL) should not be used as condition for ternary operator. Submitted by: Tatsuki Makino Approved by: re (kib) MFC after: 1 week --- sys/netpfil/ipfw/ip_fw2.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/netpfil/ipfw/ip_fw2.c b/sys/netpfil/ipfw/ip_fw2.c index de0018ec2eb6..254d3bb7bb15 100644 --- a/sys/netpfil/ipfw/ip_fw2.c +++ b/sys/netpfil/ipfw/ip_fw2.c @@ -2355,13 +2355,13 @@ do { \ case O_VERSRCREACH: /* Outgoing packets automatically pass/match */ - match = (hlen > 0 && ((oif != NULL) || + match = (hlen > 0 && ((oif != NULL) || ( #ifdef INET6 is_ipv6 ? verify_path6(&(args->f_id.src_ip6), NULL, args->f_id.fib) : #endif - verify_path(src_ip, NULL, args->f_id.fib))); + verify_path(src_ip, NULL, args->f_id.fib)))); break; case O_ANTISPOOF: