Thread (2 messages) flat view 2 messages, 2 authors, 2021-03-25

Re: [PATCH 2/2] net: ipv4: route.c: Remove unnecessary if()

From: David Ahern <hidden>
Date: 2021-03-25 14:37:44
Also in: lkml

On 3/23/21 9:10 PM, Yejune Deng wrote:
negative_advice handler is only called when dst is non-NULL hence the
'if (rt)' check can be removed. 'if' and 'else if' can be merged together.
And use container_of() instead of (struct rtable *).

Signed-off-by: Yejune Deng <redacted>
---
 net/ipv4/route.c | 16 ++++++----------
 1 file changed, 6 insertions(+), 10 deletions(-)

Reviewed-by: David Ahern <dsahern@kernel.org>
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help