[PATCH] appletalk: fix erroneous return value

Subsystems: networking [general], the rest

STALE3823d

2 messages, 2 authors, 2016-02-18 · open the first message on its own page

[PATCH] appletalk: fix erroneous return value

From: Anton Protopopov <hidden>
Date: 2016-02-17 15:54:10

The atalk_sendmsg() function might return wrong value ENETUNREACH
instead of -ENETUNREACH.

Signed-off-by: Anton Protopopov <redacted>
---
 net/appletalk/ddp.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/net/appletalk/ddp.c b/net/appletalk/ddp.c
index d5871ac..f066781 100644
--- a/net/appletalk/ddp.c
+++ b/net/appletalk/ddp.c
@@ -1625,7 +1625,7 @@ static int atalk_sendmsg(struct socket *sock, struct msghdr *msg, size_t len)
 
 		rt = atrtr_find(&at_hint);
 	}
-	err = ENETUNREACH;
+	err = -ENETUNREACH;
 	if (!rt)
 		goto out;
 
-- 
2.6.5

Re: [PATCH] appletalk: fix erroneous return value

From: David Miller <davem@davemloft.net>
Date: 2016-02-18 19:59:55

From: Anton Protopopov <redacted>
Date: Wed, 17 Feb 2016 10:53:59 -0500
The atalk_sendmsg() function might return wrong value ENETUNREACH
instead of -ENETUNREACH.

Signed-off-by: Anton Protopopov <redacted>
Applied.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help