Commit ae81711c authored by Max Kellermann's avatar Max Kellermann Committed by Christian Brauner

fs/pipe: remove duplicate "offset" initializer

This code duplication was introduced by commit a194dfe6 ("pipe:
Rearrange sequence in pipe_write() to preallocate slot"), but since
the pipe's mutex is locked, nobody else can modify the value
meanwhile.
Signed-off-by: default avatarMax Kellermann <max.kellermann@ionos.com>
Message-Id: <20230919074045.1066796-1-max.kellermann@ionos.com>
Signed-off-by: default avatarChristian Brauner <brauner@kernel.org>
parent be049c3a
...@@ -537,7 +537,6 @@ pipe_write(struct kiocb *iocb, struct iov_iter *from) ...@@ -537,7 +537,6 @@ pipe_write(struct kiocb *iocb, struct iov_iter *from)
break; break;
} }
ret += copied; ret += copied;
buf->offset = 0;
buf->len = copied; buf->len = copied;
if (!iov_iter_count(from)) if (!iov_iter_count(from))
......
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