nxt_unit.c (1755:3b0331284155) nxt_unit.c (1756:72e75ce3c99f)
1
2/*
3 * Copyright (C) NGINX, Inc.
4 */
5
6#include <stdlib.h>
7
8#include "nxt_main.h"

--- 3592 unchanged lines hidden (view full) ---

3601 ctx_impl = nxt_container_of(ctx, nxt_unit_ctx_impl_t, ctx);
3602
3603 while (1) {
3604 rbuf = nxt_unit_read_buf_get(ctx);
3605 if (nxt_slow_path(rbuf == NULL)) {
3606 return NXT_UNIT_ERROR;
3607 }
3608
1
2/*
3 * Copyright (C) NGINX, Inc.
4 */
5
6#include <stdlib.h>
7
8#include "nxt_main.h"

--- 3592 unchanged lines hidden (view full) ---

3601 ctx_impl = nxt_container_of(ctx, nxt_unit_ctx_impl_t, ctx);
3602
3603 while (1) {
3604 rbuf = nxt_unit_read_buf_get(ctx);
3605 if (nxt_slow_path(rbuf == NULL)) {
3606 return NXT_UNIT_ERROR;
3607 }
3608
3609 res = nxt_unit_ctx_port_recv(ctx, ctx_impl->read_port, rbuf);
3609 do {
3610 res = nxt_unit_ctx_port_recv(ctx, ctx_impl->read_port, rbuf);
3611 } while (res == NXT_UNIT_AGAIN);
3612
3610 if (res == NXT_UNIT_ERROR) {
3611 nxt_unit_read_buf_release(ctx, rbuf);
3612
3613 return NXT_UNIT_ERROR;
3614 }
3615
3616 if (nxt_unit_is_shm_ack(rbuf)) {
3617 nxt_unit_read_buf_release(ctx, rbuf);

--- 3098 unchanged lines hidden ---
3613 if (res == NXT_UNIT_ERROR) {
3614 nxt_unit_read_buf_release(ctx, rbuf);
3615
3616 return NXT_UNIT_ERROR;
3617 }
3618
3619 if (nxt_unit_is_shm_ack(rbuf)) {
3620 nxt_unit_read_buf_release(ctx, rbuf);

--- 3098 unchanged lines hidden ---