1
0
mirror of https://passt.top/passt synced 2024-12-22 13:45:32 +00:00

tcp: Change SO_PEEK_OFF support message to debug()

This:

  $ ./pasta
  SO_PEEK_OFF not supported
  #

is a bit annoying, and might trick users who face other issues into
thinking that SO_PEEK_OFF not being supported on a given kernel is
an actual issue.

Even if SO_PEEK_OFF is supported by the kernel, that would be the
only message displayed there, with default options, which looks a bit
out of context.

Switch that to debug(): now that Podman users can pass --debug too, we
can find out quickly if it's supported or not, if SO_PEEK_OFF usage is
suspected of causing any issue.

Signed-off-by: Stefano Brivio <sbrivio@redhat.com>
Reviewed-by: David Gibson <david@gibson.dropbear.id.au>
This commit is contained in:
Stefano Brivio 2024-07-24 14:49:00 +02:00
parent d19b396f11
commit 13295583f8

2
tcp.c
View File

@ -2524,7 +2524,7 @@ int tcp_init(struct ctx *c)
peek_offset_cap = (!c->ifi4 || tcp_probe_peek_offset_cap(AF_INET)) && peek_offset_cap = (!c->ifi4 || tcp_probe_peek_offset_cap(AF_INET)) &&
(!c->ifi6 || tcp_probe_peek_offset_cap(AF_INET6)); (!c->ifi6 || tcp_probe_peek_offset_cap(AF_INET6));
info("SO_PEEK_OFF%ssupported", peek_offset_cap ? " " : " not "); debug("SO_PEEK_OFF%ssupported", peek_offset_cap ? " " : " not ");
return 0; return 0;
} }