On 9/15/19 3:08 AM, Julian Anastasov wrote: > Now I see commit 1550c171935d wrongly changes that to > "If rt_gw_family is set it implies rt_uses_gateway.". > As result, we set rt_gw_family while rt_uses_gateway was 0 > for above cases. Think about it in this way: there should be > a reason why we used rt_uses_gateway flag instead a simple > "rt_gateway != 0" check, right? > > Replacing rt->rt_gateway checks with rt_gw_family > checks is right but rt_uses_gateway checks should be put > back because they indicates the route has more hops to > target. > > As the problem is related to some FNHW and non-cached > routes, redirects, etc the easiest way to see the problem is with > 'ip route get LOCAL_IP oif eth0' where extra 'via GW' line is > shown.
Hi Julian: Thanks for the detailed report. Yes, I misunderstood the subtle point of rt_uses_gateway. I will look at a fix this week. David