projects
/
GitHub
/
MotorolaMobilityLLC
/
kernel-slsi.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
e46662b
)
net/9p: set error to EREMOTEIO if trans->write returns zero
author
Latchesar Ionkov
<lucho@ionkov.net>
Wed, 11 Jul 2007 21:14:46 +0000
(15:14 -0600)
committer
Eric Van Hensbergen
<ericvh@ericvh-desktop.austin.ibm.com>
Sat, 14 Jul 2007 20:14:01 +0000
(15:14 -0500)
If trans->write returns 0, p9_write_work goes through the error path, but
sets the error code to zero.
This patch sets the error code to EREMOTEIO if trans->write returns zero
value.
Signed-off-by: Latchesar Ionkov <lucho@ionkov.net>
net/9p/mux.c
patch
|
blob
|
blame
|
history
diff --git
a/net/9p/mux.c
b/net/9p/mux.c
index c3aa87bc8b973c724e207a41ce54e9244620ad0d..acb038810f3995c2b5c4b7e742d91e34c33d83bc 100644
(file)
--- a/
net/9p/mux.c
+++ b/
net/9p/mux.c
@@
-505,8
+505,12
@@
again:
return;
}
- if (err <= 0)
+ if (err < 0)
+ goto error;
+ else if (err == 0) {
+ err = -EREMOTEIO;
goto error;
+ }
m->wpos += err;
if (m->wpos == m->wsize)