projects
/
firefly-linux-kernel-4.4.55.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
4b087b2
)
[TIPC]: Simplify code for returning partial success of stream send request.
author
Allan Stephens
<allan.stephens@windriver.com>
Mon, 26 Jun 2006 06:48:22 +0000
(23:48 -0700)
committer
David S. Miller
<davem@davemloft.net>
Mon, 26 Jun 2006 06:48:22 +0000
(23:48 -0700)
Signed-off-by: Allan Stephens <allan.stephens@windriver.com>
Signed-off-by: Per Liden <per.liden@ericsson.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/tipc/socket.c
patch
|
blob
|
history
diff --git
a/net/tipc/socket.c
b/net/tipc/socket.c
index abecf2d422ff98d5cb491d5d432488ccf097cc0b..6d4d2b0063aa8c6a49dfb8b477db700b633ef456 100644
(file)
--- a/
net/tipc/socket.c
+++ b/
net/tipc/socket.c
@@
-969,7
+969,7
@@
static int recv_stream(struct kiocb *iocb, struct socket *sock,
restart:
if (unlikely((skb_queue_len(&sock->sk->sk_receive_queue) == 0) &&
(flags & MSG_DONTWAIT))) {
- res =
(sz_copied == 0) ? -EWOULDBLOCK : 0
;
+ res =
-EWOULDBLOCK
;
goto exit;
}
@@
-1060,7
+1060,7
@@
restart:
exit:
up(&tsock->sem);
- return
res ? res : sz_copied
;
+ return
sz_copied ? sz_copied : res
;
}
/**