We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent ddd2ab7 commit 926e1b1Copy full SHA for 926e1b1
1 file changed
examples/zcrx.c
@@ -332,6 +332,19 @@ static void return_buffer(struct io_uring_zcrx_rq *rq_ring,
332
333
static void process_recvzc_error(struct io_uring *ring, int ret)
334
{
335
+ if (ret == -ENOSPC) {
336
+ size_t left = 0;
337
+
338
+ if (cfg_size) {
339
+ left = cfg_size - received;
340
+ if (left == 0)
341
+ t_error(1, 0, "ENOSPC for a finished request");
342
+ }
343
344
+ add_recvzc(ring, connfd, left);
345
+ return;
346
347
348
if (ret != 0)
349
t_error(1, 0, "invalid final recvzc ret %i", ret);
350
if (cfg_size && received != cfg_size)
0 commit comments