Lines Matching refs:p_max_bytes
131 static int network_write_accounting(const int fd, chunkqueue * const cq, off_t * const p_max_bytes,… in network_write_accounting() argument
133 *p_max_bytes -= wr;/*(toSend > 0 if we reach this func)*/ in network_write_accounting()
134 const int rc = (wr == toSend && *p_max_bytes > 0) ? 0 : -3; in network_write_accounting()
149 static int network_write_mem_chunk(const int fd, chunkqueue * const cq, off_t * const p_max_bytes, … in network_write_mem_chunk() argument
152 if (c_len > *p_max_bytes) c_len = *p_max_bytes; in network_write_mem_chunk()
156 return network_write_accounting(fd, cq, p_max_bytes, errh, wr, c_len); in network_write_mem_chunk()
164 …_file_chunk_no_mmap(const int fd, chunkqueue * const cq, off_t * const p_max_bytes, log_error_st *… in network_write_file_chunk_no_mmap() argument
169 if (toSend > *p_max_bytes) toSend = *p_max_bytes; in network_write_file_chunk_no_mmap()
182 return network_write_accounting(fd, cq, p_max_bytes, errh, wr, toSend); in network_write_file_chunk_no_mmap()
199 …ite_file_chunk_mmap(const int fd, chunkqueue * const cq, off_t * const p_max_bytes, log_error_st *… in network_write_file_chunk_mmap() argument
205 return network_write_file_chunk_no_mmap(fd, cq, p_max_bytes, errh); in network_write_file_chunk_mmap()
208 if (toSend > *p_max_bytes) toSend = *p_max_bytes; in network_write_file_chunk_mmap()
216 return network_write_accounting(fd,cq,p_max_bytes,errh,(ssize_t)wr,toSend); in network_write_file_chunk_mmap()
254 static int network_writev_mem_chunks(const int fd, chunkqueue * const cq, off_t * const p_max_bytes… in network_writev_mem_chunks() argument
267 if (++num_chunks == MAX_CHUNKS || toSend >= *p_max_bytes) break; in network_writev_mem_chunks()
275 return network_write_accounting(fd, cq, p_max_bytes, errh, wr, toSend); in network_writev_mem_chunks()
295 …file_chunk_sendfile(const int fd, chunkqueue * const cq, off_t * const p_max_bytes, log_error_st *… in network_write_file_chunk_sendfile() argument
304 if (toSend > *p_max_bytes) toSend = *p_max_bytes; in network_write_file_chunk_sendfile()
371 return network_write_file_chunk_mmap(fd, cq, p_max_bytes, errh); in network_write_file_chunk_sendfile()
373 return network_write_file_chunk_no_mmap(fd, cq, p_max_bytes, errh); in network_write_file_chunk_sendfile()
383 *p_max_bytes -= written; in network_write_file_chunk_sendfile()
384 if (__builtin_expect( (*p_max_bytes <= 0), 0)) return -3; in network_write_file_chunk_sendfile()