nxt_job_file.c (65:10688b89aa16) nxt_job_file.c (237:491330b10958)
1
2/*
3 * Copyright (C) Igor Sysoev
4 * Copyright (C) NGINX, Inc.
5 */
6
7
8#include <nxt_main.h>

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

272}
273
274
275static nxt_int_t
276nxt_job_file_read_data(nxt_job_file_t *jbf, size_t size)
277{
278 ssize_t n;
279
1
2/*
3 * Copyright (C) Igor Sysoev
4 * Copyright (C) NGINX, Inc.
5 */
6
7
8#include <nxt_main.h>

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

272}
273
274
275static nxt_int_t
276nxt_job_file_read_data(nxt_job_file_t *jbf, size_t size)
277{
278 ssize_t n;
279
280 n = nxt_file_read(&jbf->file, jbf->buffer->mem.pos, size, jbf->offset);
280 n = nxt_file_read(&jbf->file, jbf->buffer->mem.free, size, jbf->offset);
281
282 if (nxt_fast_path(n > 0)) {
283
284 jbf->buffer->mem.free += n;
285 jbf->offset += n;
286
287 if (nxt_buf_is_file(jbf->buffer)) {
288 jbf->buffer->file_end += n;

--- 14 unchanged lines hidden ---
281
282 if (nxt_fast_path(n > 0)) {
283
284 jbf->buffer->mem.free += n;
285 jbf->offset += n;
286
287 if (nxt_buf_is_file(jbf->buffer)) {
288 jbf->buffer->file_end += n;

--- 14 unchanged lines hidden ---