Lines Matching refs:len
23 static int http_chunk_append_len(server *srv, connection *con, size_t len) { in http_chunk_append_len() argument
24 size_t i, olen = len, j; in http_chunk_append_len()
29 if (len == 0) { in http_chunk_append_len()
32 for (i = 0; i < 8 && len; i++) { in http_chunk_append_len()
33 len >>= 4; in http_chunk_append_len()
39 for (j = i-1, len = olen; j+1 > 0; j--) { in http_chunk_append_len()
40 b->ptr[j] = (len & 0xf) + (((len & 0xf) <= 9) ? '0' : 'a' - 10); in http_chunk_append_len()
41 len >>= 4; in http_chunk_append_len()
54 int http_chunk_append_file(server *srv, connection *con, buffer *fn, off_t offset, off_t len) { in http_chunk_append_file() argument
62 http_chunk_append_len(srv, con, len); in http_chunk_append_file()
65 chunkqueue_append_file(cq, fn, offset, len); in http_chunk_append_file()
67 if (con->response.transfer_encoding & HTTP_TRANSFER_ENCODING_CHUNKED && len > 0) { in http_chunk_append_file()
94 int http_chunk_append_mem(server *srv, connection *con, const char * mem, size_t len) { in http_chunk_append_mem() argument
101 if (len == 0) { in http_chunk_append_mem()
111 http_chunk_append_len(srv, con, len - 1); in http_chunk_append_mem()
114 chunkqueue_append_mem(cq, mem, len); in http_chunk_append_mem()