diff options
author | Wojciech Lukowicz <wlukowicz01@gmail.com> | 2024-02-20 19:25:03 +0000 |
---|---|---|
committer | Wojciech Lukowicz <wlukowicz01@gmail.com> | 2024-02-20 20:55:12 +0000 |
commit | 3ae058eb09afaa2bce9ecd3c410f5c6476008e47 (patch) | |
tree | 05babc7fa165e63954cd5d4ebf76275b2d233ead | |
parent | af77bf2a82d2e71ffd1c353114ec24634c6e6d25 (diff) | |
download | liburing-3ae058eb09afaa2bce9ecd3c410f5c6476008e47.tar.gz |
examples/proxy: fix send ring default when unavailable
When IORING_FEAT_SEND_BUFS is unavailable, the default stays as -1
which means the proxy tries to use it and fails:
Backend: (...), send_buf_ring=-1
(...)
0: SEND error Operation not supported
This change makes send ring always off when unavailable.
Fixes: 6a5174b3dccf ("examples/proxy: add support for provided buffers for sends")
Signed-off-by: Wojciech Lukowicz <wlukowicz01@gmail.com>
-rw-r--r-- | examples/proxy.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/examples/proxy.c b/examples/proxy.c index 24a92818..6207156b 100644 --- a/examples/proxy.c +++ b/examples/proxy.c @@ -1555,8 +1555,8 @@ int main(int argc, char *argv[]) if (send_ring == 1) { fprintf(stderr, "Kernel doesn't support ring provided " "buffers for sends, disabled\n"); - send_ring = 0; } + send_ring = 0; } if (fixed_files) { |