Commit a835be5b authored by Nicolas Kaiser's avatar Nicolas Kaiser Committed by Greg Kroah-Hartman

pipe: fix failure to return error code on ->confirm()

commit e5953cbd upstream.

The arguments were transposed, we want to assign the error code to
'ret', which is being returned.
Signed-off-by: default avatarNicolas Kaiser <nikai@nikai.net>
Signed-off-by: default avatarJens Axboe <jaxboe@fusionio.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
parent 325d960f
...@@ -363,7 +363,7 @@ pipe_read(struct kiocb *iocb, const struct iovec *_iov, ...@@ -363,7 +363,7 @@ pipe_read(struct kiocb *iocb, const struct iovec *_iov,
error = ops->confirm(pipe, buf); error = ops->confirm(pipe, buf);
if (error) { if (error) {
if (!ret) if (!ret)
error = ret; ret = error;
break; break;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment