Re: in6_selectroute should never get AF_INET filled struct route *

2016-09-02 Thread Florian Obser
OK florian@ On Fri, Sep 02, 2016 at 11:21:33AM +0200, Vincent Gross wrote: > in6_selectroute() checks whether the struct route it received contains > a valid route whose AF is not AF_INET6, "in case the cache is shared". > Well, is this cache shared or not ? > > There&

in6_selectroute should never get AF_INET filled struct route *

2016-09-02 Thread Vincent Gross
in6_selectroute() checks whether the struct route it received contains a valid route whose AF is not AF_INET6, "in case the cache is shared". Well, is this cache shared or not ? There's only two ways to get to in6_selectroute() 1) in6_pcbselsrc() -> in6_selectif() -> in

Re: 'struct route' and syncache

2016-08-30 Thread Jeremie Courreges-Anglas
Martin Pieuchot writes: > Use 'sc_route{4,6}' directly instead of casting to the almost extinct > 'struct route *'. This help fixing remaining use of 'struct route'. > > ok? ok -- jca | PGP : 0x1524E7EE / 5135 92C1 AD36 5293 2BDF DDCC 0DFA 74AE 1524 E7EE

'struct route' and syncache

2016-08-29 Thread Martin Pieuchot
Use 'sc_route{4,6}' directly instead of casting to the almost extinct 'struct route *'. This help fixing remaining use of 'struct route'. ok? Index: netinet/tcp_input.c === RCS file: /cvs/src/sys/ne

Re: pf(4) and "struct route"

2014-12-09 Thread Alexander Bluhm
gt; --- net/pf.c 20 Nov 2014 13:54:24 - 1.896 > +++ net/pf.c 8 Dec 2014 11:02:48 - > @@ -2952,42 +2952,36 @@ pf_calc_mss(struct pf_addr *addr, sa_fam > { > #ifdef INET > struct sockaddr_in *dst; > - struct route ro; > #endif /* INET *

Re: pf(4) and "struct route"

2014-12-08 Thread Martin Pieuchot
RCS file: /home/ncvs/src/sys/net/pf.c,v retrieving revision 1.896 diff -u -p -r1.896 pf.c --- net/pf.c 20 Nov 2014 13:54:24 - 1.896 +++ net/pf.c8 Dec 2014 11:02:48 - @@ -2952,42 +2952,36 @@ pf_calc_mss(struct pf_addr

Re: pf(4) and "struct route"

2014-12-03 Thread Alexander Bluhm
On Wed, Nov 26, 2014 at 03:21:43PM +0100, Martin Pieuchot wrote: > @@ -5459,7 +5448,6 @@ pf_routable(struct pf_addr *addr, sa_fam > > /* Perform uRPF check if passed input interface */ > ret = 0; > - rt = ro.ro_rt; > do { >

Re: struct route

2014-12-03 Thread Alexander Bluhm
On Tue, Nov 25, 2014 at 04:39:38PM +0100, Martin Pieuchot wrote: > 3 places where we don't need any "struct route". ok? OK bluhm@ > > Index: netinet/ip_icmp.c > === > RCS file: /home/ncvs/src/sys/ne

Re: pf(4) and "struct route"

2014-11-26 Thread Todd C. Miller
On Wed, 26 Nov 2014 15:21:43 +0100, Martin Pieuchot wrote: > And know with the correct diff... Looks good. - todd

Re: pf(4) and "struct route"

2014-11-26 Thread Martin Pieuchot
On 26/11/14(Wed) 13:32, Martin Pieuchot wrote: > On 25/11/14(Tue) 15:16, Todd C. Miller wrote: > > On Tue, 25 Nov 2014 16:43:16 +0100, Martin Pieuchot wrote: > > > > > Diff below removes the non-needed usages of "struct route" & friends in > > > pf.

Re: pf(4) and "struct route"

2014-11-26 Thread Martin Pieuchot
On 25/11/14(Tue) 15:16, Todd C. Miller wrote: > On Tue, 25 Nov 2014 16:43:16 +0100, Martin Pieuchot wrote: > > > Diff below removes the non-needed usages of "struct route" & friends in > > pf.c, any comment or ok? > > You are missing some initializations o

Re: struct route

2014-11-25 Thread Todd C. Miller
On Tue, 25 Nov 2014 16:39:38 +0100, Martin Pieuchot wrote: > 3 places where we don't need any "struct route". ok? Looks correct. I think the existing ip_setmoptions() uses stack garbage for some of its tests since only ro.ro_rt is cleared so this is an improvement. Strictly

Re: pf(4) and "struct route"

2014-11-25 Thread Todd C. Miller
On Tue, 25 Nov 2014 16:43:16 +0100, Martin Pieuchot wrote: > Diff below removes the non-needed usages of "struct route" & friends in > pf.c, any comment or ok? You are missing some initializations of rt to NULL, comments inline. - tod

pf(4) and "struct route"

2014-11-25 Thread Martin Pieuchot
Diff below removes the non-needed usages of "struct route" & friends in pf.c, any comment or ok? Index: net/pf.c === RCS file: /home/ncvs/src/sys/net/pf.c,v retrieving revision 1.896 diff -u -p -r1.896 pf.c --- net/

struct route

2014-11-25 Thread Martin Pieuchot
3 places where we don't need any "struct route". ok? Index: netinet/ip_icmp.c === RCS file: /home/ncvs/src/sys/netinet/ip_icmp.c,v retrieving revision 1.126 diff -u -p -r1.126 ip_icmp.c --- netinet/ip_icmp.c 1 No