summaryrefslogtreecommitdiffstats
path: root/net/ipv4/route.c
diff options
context:
space:
mode:
authorJeff Garzik <jgarzik@pobox.com>2005-06-30 06:49:38 +0200
committerJeff Garzik <jgarzik@pobox.com>2005-06-30 06:49:38 +0200
commite9dd2561793c05d70c9df1bc16a2dde6f23388df (patch)
tree20099972569cc0748133a6351600fff9cbb15f4a /net/ipv4/route.c
parentMerge /spare/repo/netdev-2.6 branch 'ieee80211' (diff)
parentMerge upstream 2.6.13-rc1-git1 into 'ieee80211' branch of netdev-2.6. (diff)
downloadlinux-e9dd2561793c05d70c9df1bc16a2dde6f23388df.tar.xz
linux-e9dd2561793c05d70c9df1bc16a2dde6f23388df.zip
Merge /spare/repo/netdev-2.6 branch 'ieee80211'
Diffstat (limited to 'net/ipv4/route.c')
-rw-r--r--net/ipv4/route.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/net/ipv4/route.c b/net/ipv4/route.c
index 80cf633d9f4a..12a1cf306f67 100644
--- a/net/ipv4/route.c
+++ b/net/ipv4/route.c
@@ -1909,7 +1909,7 @@ static int ip_route_input_slow(struct sk_buff *skb, u32 daddr, u32 saddr,
*/
if ((err = fib_lookup(&fl, &res)) != 0) {
if (!IN_DEV_FORWARD(in_dev))
- goto e_inval;
+ goto e_hostunreach;
goto no_route;
}
free_res = 1;
@@ -1933,7 +1933,7 @@ static int ip_route_input_slow(struct sk_buff *skb, u32 daddr, u32 saddr,
}
if (!IN_DEV_FORWARD(in_dev))
- goto e_inval;
+ goto e_hostunreach;
if (res.type != RTN_UNICAST)
goto martian_destination;
@@ -2025,6 +2025,11 @@ martian_destination:
"%u.%u.%u.%u, dev %s\n",
NIPQUAD(daddr), NIPQUAD(saddr), dev->name);
#endif
+
+e_hostunreach:
+ err = -EHOSTUNREACH;
+ goto done;
+
e_inval:
err = -EINVAL;
goto done;