netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Niv Yehezkel <executerx@gmail.com>
To: "David S. Miller" <davem@davemloft.net>, netdev@vger.kernel.org
Subject: [PATCH] ipv4: removed redundant conditional
Date: Fri, 8 Aug 2014 04:27:37 -0400	[thread overview]
Message-ID: <20140808082737.GA3847@localhost.localdomain> (raw)

Since fib_lookup cannot return ESRCH no longer,
checking for this error code is no longer neccesary.

Signed-off-by: Niv Yehezkel <executerx@gmail.com>
---
 net/ipv4/route.c |    2 --
 1 file changed, 2 deletions(-)

diff --git a/net/ipv4/route.c b/net/ipv4/route.c
index 082239f..23175cb 100644
--- a/net/ipv4/route.c
+++ b/net/ipv4/route.c
@@ -1771,8 +1771,6 @@ local_input:
 no_route:
 	RT_CACHE_STAT_INC(in_no_route);
 	res.type = RTN_UNREACHABLE;
-	if (err == -ESRCH)
-		err = -ENETUNREACH;
 	goto local_input;
 
 	/*
-- 
1.7.10.4

             reply	other threads:[~2014-08-08  8:27 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-08-08  8:27 Niv Yehezkel [this message]
2014-08-08 17:22 ` [PATCH] ipv4: removed redundant conditional David Miller

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20140808082737.GA3847@localhost.localdomain \
    --to=executerx@gmail.com \
    --cc=davem@davemloft.net \
    --cc=netdev@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).