$NetBSD: patch-ac,v 1.1 2006/01/23 18:46:00 tron Exp $ Index: ipstat/config.c =================================================================== RCS file: /share/cvsroot/net/ipstat/ipstat/config.c,v retrieving revision 1.6 retrieving revision 1.7 diff -u -r1.6 -r1.7 --- ipstat/config.c 30 Dec 2004 21:41:39 -0000 1.6 +++ ipstat/config.c 23 Jan 2006 13:13:56 -0000 1.7 @@ -312,8 +312,8 @@ { struct in_addr *Addr,*Mask; - Addr=&((Type==0)?Mt->m_SrcAddr:Mt->m_DstAddr); - Mask=&((Type==0)?Mt->m_SrcMask:Mt->m_DstMask); + Addr=((Type==0)?&Mt->m_SrcAddr:&Mt->m_DstAddr); + Mask=((Type==0)?&Mt->m_SrcMask:&Mt->m_DstMask); if (!ParseNet(*Arg,Addr,Mask)) { (void)fprintf(stderr, @@ -362,7 +362,8 @@ return FALSE; } - ((Type==3)?Mt->m_SrcPort:Mt->m_DstPort)=Port; + if (Type==3) Mt->m_SrcPort=Port; + else Mt->m_DstPort=Port; } }