tcp_splice: fcntl(2) returns the size of the pipe, if F_SETPIPE_SZ succeeds
Don't report bogus failures (with --trace) just because the return value is not zero. Link: https://github.com/containers/podman/issues/24219 Signed-off-by: Stefano Brivio <sbrivio@redhat.com> Reviewed-by: David Gibson <david@gibson.dropbear.id.au>
This commit is contained in:
parent
149f457b23
commit
9e4615b40b
1 changed files with 2 additions and 2 deletions
|
@ -320,7 +320,7 @@ static int tcp_splice_connect_finish(const struct ctx *c,
|
||||||
}
|
}
|
||||||
|
|
||||||
if (fcntl(conn->pipe[sidei][0], F_SETPIPE_SZ,
|
if (fcntl(conn->pipe[sidei][0], F_SETPIPE_SZ,
|
||||||
c->tcp.pipe_size)) {
|
c->tcp.pipe_size) != (int)c->tcp.pipe_size) {
|
||||||
flow_trace(conn,
|
flow_trace(conn,
|
||||||
"cannot set %d->%d pipe size to %zu",
|
"cannot set %d->%d pipe size to %zu",
|
||||||
sidei, !sidei, c->tcp.pipe_size);
|
sidei, !sidei, c->tcp.pipe_size);
|
||||||
|
@ -672,7 +672,7 @@ static void tcp_splice_pipe_refill(const struct ctx *c)
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
if (fcntl(splice_pipe_pool[i][0], F_SETPIPE_SZ,
|
if (fcntl(splice_pipe_pool[i][0], F_SETPIPE_SZ,
|
||||||
c->tcp.pipe_size)) {
|
c->tcp.pipe_size) != (int)c->tcp.pipe_size) {
|
||||||
trace("TCP (spliced): cannot set pool pipe size to %zu",
|
trace("TCP (spliced): cannot set pool pipe size to %zu",
|
||||||
c->tcp.pipe_size);
|
c->tcp.pipe_size);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue