Skip to content

Commit e5953cb

Browse files
nikai3dJens Axboe
authored andcommitted
pipe: fix failure to return error code on ->confirm()
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> Cc: stable@kernel.org Signed-off-by: Jens Axboe <jaxboe@fusionio.com>
1 parent f6f94e2 commit e5953cb

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

‎fs/pipe.c‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -382,7 +382,7 @@ pipe_read(struct kiocb *iocb, const struct iovec *_iov,
382382
error = ops->confirm(pipe, buf);
383383
if (error) {
384384
if (!ret)
385-
error = ret;
385+
ret = error;
386386
break;
387387
}
388388

0 commit comments

Comments
 (0)