aboutgitcodebugslistschat
path: root/tcp.h
diff options
context:
space:
mode:
authorStefano Brivio <sbrivio@redhat.com>2021-10-21 01:19:27 +0200
committerStefano Brivio <sbrivio@redhat.com>2021-10-21 01:19:27 +0200
commit849308d20716f40452e70a230f3a403ee88b207d (patch)
tree178d07059fb5a95c1d8c9cf923be4dd532fa274d /tcp.h
parenta20626fb3516169c8c06bd1729cf29465d2cbd1f (diff)
downloadpasst-849308d20716f40452e70a230f3a403ee88b207d.tar
passt-849308d20716f40452e70a230f3a403ee88b207d.tar.gz
passt-849308d20716f40452e70a230f3a403ee88b207d.tar.bz2
passt-849308d20716f40452e70a230f3a403ee88b207d.tar.lz
passt-849308d20716f40452e70a230f3a403ee88b207d.tar.xz
passt-849308d20716f40452e70a230f3a403ee88b207d.tar.zst
passt-849308d20716f40452e70a230f3a403ee88b207d.zip
Makefile, tcp: Don't try to use tcpi_snd_wnd from tcp_info on pre-5.3 kernels
Detect missing tcpi_snd_wnd in struct tcp_info at build time, otherwise build fails with a pre-5.3 linux/tcp.h header. Signed-off-by: Stefano Brivio <sbrivio@redhat.com>
Diffstat (limited to 'tcp.h')
-rw-r--r--tcp.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/tcp.h b/tcp.h
index bfd6082..dc854b8 100644
--- a/tcp.h
+++ b/tcp.h
@@ -67,7 +67,9 @@ struct tcp_ctx {
uint8_t port_to_init [USHRT_MAX / 8];
int ns_detect_ports;
struct timespec timer_run;
+#ifdef HAS_SND_WND
int kernel_snd_wnd;
+#endif
size_t pipe_size;
struct timespec refill_ts;
struct timespec port_detect_ts;