summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNicolas Kaiser <nikai@nikai.net>2010-10-21 14:56:00 +0200
committerPaul Gortmaker <paul.gortmaker@windriver.com>2011-01-06 18:08:22 -0500
commit60534386c08a9bea1049415f88b8c976d27d5be0 (patch)
tree2033c4bc5ddc6b9fe6e23471938337d7fd352348
parent69536bef5b84796e183b96fbc6f1dac1dce6dfd1 (diff)
pipe: fix failure to return error code on ->confirm()
commit e5953cbdff26f7cbae7eff30cd9b18c4e19b7594 upstream. The arguments were transposed, we want to assign the error code to 'ret', which is being returned. Signed-off-by: Nicolas Kaiser <nikai@nikai.net> Signed-off-by: Jens Axboe <jaxboe@fusionio.com> Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
-rw-r--r--fs/pipe.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/pipe.c b/fs/pipe.c
index 37ba29ff3158..8087027e9ccb 100644
--- a/fs/pipe.c
+++ b/fs/pipe.c
@@ -363,7 +363,7 @@ pipe_read(struct kiocb *iocb, const struct iovec *_iov,
error = ops->confirm(pipe, buf);
if (error) {
if (!ret)
- error = ret;
+ ret = error;
break;
}