Home
last modified time | relevance | path

Searched refs:pos (Results 1 – 25 of 49) sorted by relevance

12

/unit/src/java/
H A Dnxt_jni_HeaderNamesEnumeration.c95 if (pos >= size) { in nxt_java_HeaderNamesEnumeration_nextElementPos()
99 if (pos > 0) { in nxt_java_HeaderNamesEnumeration_nextElementPos()
101 && f[pos].hash == f[pos - 1].hash in nxt_java_HeaderNamesEnumeration_nextElementPos()
102 && f[pos].name_length == f[pos - 1].name_length) in nxt_java_HeaderNamesEnumeration_nextElementPos()
104 pos++; in nxt_java_HeaderNamesEnumeration_nextElementPos()
108 return pos; in nxt_java_HeaderNamesEnumeration_nextElementPos()
122 if (pos > 0) { in nxt_java_HeaderNamesEnumeration_nextElement()
124 && f[pos].hash == f[pos - 1].hash in nxt_java_HeaderNamesEnumeration_nextElement()
125 && f[pos].name_length == f[pos - 1].name_length) in nxt_java_HeaderNamesEnumeration_nextElement()
127 pos++; in nxt_java_HeaderNamesEnumeration_nextElement()
[all …]
H A Dnxt_jni_HeadersEnumeration.c23 jclass cls, jlong headers_ptr, jlong size, jlong ipos, jlong pos);
26 jclass cls, jlong headers_ptr, jlong size, jlong ipos, jlong pos);
78 uint32_t fields_count, uint32_t pos) in nxt_java_newHeadersEnumeration() argument
83 (jlong) fields_count, (jlong) pos); in nxt_java_newHeadersEnumeration()
89 jlong headers_ptr, jlong size, jlong ipos, jlong pos) in nxt_java_HeadersEnumeration_nextElementPos() argument
97 if (pos >= size) { in nxt_java_HeadersEnumeration_nextElementPos()
101 f += pos; in nxt_java_HeadersEnumeration_nextElementPos()
116 return pos; in nxt_java_HeadersEnumeration_nextElementPos()
122 jlong headers_ptr, jlong size, jlong ipos, jlong pos) in nxt_java_HeadersEnumeration_nextElement() argument
130 if (pos >= size) { in nxt_java_HeadersEnumeration_nextElement()
[all …]
H A Dnxt_jni_HeadersEnumeration.h17 uint32_t fields_count, uint32_t pos);
/unit/test/unit/
H A Dlog.py6 pos = {} variable in Log
10 f.seek(Log.pos.get(name, 0))
14 def set_pos(pos, name=UNIT_LOG): argument
15 Log.pos[name] = pos
18 pos = Log.pos.get(UNIT_LOG, 0)
19 Log.pos[UNIT_LOG] = Log.pos.get(name, 0)
20 Log.pos[name] = pos
/unit/src/java/nginx/unit/
H A DHeaderNamesEnumeration.java11 private long pos = 0; field in HeaderNamesEnumeration
21 if (pos >= size) { in hasMoreElements()
25 pos = nextElementPos(headers_ptr, size, pos); in hasMoreElements()
26 return pos < size; in hasMoreElements()
29 static private native long nextElementPos(long headers_ptr, long size, long pos); in nextElementPos() argument
34 if (pos >= size) { in nextElement()
38 return nextElement(headers_ptr, size, pos++); in nextElement()
41 static private native String nextElement(long headers_ptr, long size, long pos); in nextElement() argument
H A DHeadersEnumeration.java11 private long pos; field in HeadersEnumeration
17 pos = _initial_pos; in HeadersEnumeration()
23 if (pos >= size) { in hasMoreElements()
27 pos = nextElementPos(headers_ptr, size, initial_pos, pos); in hasMoreElements()
28 return pos < size; in hasMoreElements()
31 …static private native long nextElementPos(long headers_ptr, long size, long initial_pos, long pos); in nextElementPos() argument
36 return nextElement(headers_ptr, size, initial_pos, pos++); in nextElement()
39 … static private native String nextElement(long headers_ptr, long size, long initial_pos, long pos); in nextElement() argument
/unit/src/
H A Dnxt_sendbuf.c39 size = b->mem.free - b->mem.pos; in nxt_sendbuf_mem_coalesce0()
51 if (b->mem.pos != last) { in nxt_sendbuf_mem_coalesce0()
68 last = b->mem.pos + size; in nxt_sendbuf_mem_coalesce0()
123 if (b->mem.pos != last) { in nxt_sendbuf_mem_coalesce()
231 if (bm->pos == NULL) { in nxt_sendbuf_copy_coalesce()
232 bm->pos = nxt_malloc(bsize); in nxt_sendbuf_copy_coalesce()
237 bm->start = bm->pos; in nxt_sendbuf_copy_coalesce()
238 bm->free = bm->pos; in nxt_sendbuf_copy_coalesce()
263 bm->pos += n; in nxt_sendbuf_copy_coalesce()
265 if (bm->pos == bm->free) { in nxt_sendbuf_copy_coalesce()
[all …]
H A Dnxt_solaris_sendfilev.c96 nxt_off_t pos, last_pos; in nxt_solaris_buf_coalesce() local
108 pos = b->file_pos; in nxt_solaris_buf_coalesce()
109 size = b->file_end - pos; in nxt_solaris_buf_coalesce()
122 pos = (uintptr_t) b->mem.pos; in nxt_solaris_buf_coalesce()
123 size = b->mem.free - b->mem.pos; in nxt_solaris_buf_coalesce()
142 if (fd != last_fd || pos != last_pos) { in nxt_solaris_buf_coalesce()
150 sfv[i].sfv_off = pos; in nxt_solaris_buf_coalesce()
158 last_pos = pos + size; in nxt_solaris_buf_coalesce()
H A Dnxt_http_parse.c70 p = *pos; in nxt_http_parse_target()
172 p = *pos; in nxt_http_parse_request_line()
486 p = *pos; in nxt_http_parse_unusual_target()
505 *pos = p; in nxt_http_parse_unusual_target()
581 len = p - *pos; in nxt_http_parse_field_name()
612 *pos = p + 1; in nxt_http_parse_field_name()
632 p = *pos; in nxt_http_parse_field_value()
636 *pos = p; in nxt_http_parse_field_value()
684 *pos = p; in nxt_http_parse_field_value()
779 p = *pos; in nxt_http_parse_field_end()
[all …]
H A Dnxt_fastcgi_record_parse.c57 fp->pos = b->mem.pos; in nxt_fastcgi_record_parse()
59 while (fp->pos < b->mem.free) { in nxt_fastcgi_record_parse()
98 ch = *fp->pos++; in nxt_fastcgi_record_parse()
260 p = fp->pos; in nxt_fastcgi_buffer()
268 in->mem.pos = p; in nxt_fastcgi_buffer()
283 b->mem.pos = p; in nxt_fastcgi_buffer()
288 fp->pos = p; in nxt_fastcgi_buffer()
H A Dnxt_http_chunk_parse.c51 hcp->pos = b->mem.pos; in nxt_http_chunk_parse()
53 while (hcp->pos < b->mem.free) { in nxt_http_chunk_parse()
79 ch = *hcp->pos++; in nxt_http_chunk_parse()
206 p = hcp->pos; in nxt_http_chunk_buffer()
222 b->mem.pos = p; in nxt_http_chunk_buffer()
227 hcp->pos = p; in nxt_http_chunk_buffer()
H A Dnxt_http_websocket.c50 wsh = (nxt_websocket_header_t *) r->ws_frame->mem.pos; in nxt_http_websocket_client()
79 buf->mem.free = nxt_cpymem(buf->mem.free, b->mem.pos, in nxt_http_websocket_client()
83 b->mem.pos += chunk_copy_size; in nxt_http_websocket_client()
115 nxt_memmove(b->mem.start, b->mem.pos, used_size); in nxt_http_websocket_client()
117 b->mem.pos = b->mem.start; in nxt_http_websocket_client()
H A Dnxt_buf.c24 b->mem.pos = start; in nxt_buf_mem_init()
47 b->mem.pos = b->mem.start; in nxt_buf_mem_alloc()
78 b->mem.pos = b->mem.start; in nxt_buf_mem_ts_alloc()
113 b->mem.pos = b->mem.start; in nxt_buf_file_alloc()
187 length += b->mem.free - b->mem.pos; in nxt_buf_chain_length()
232 parent->mem.pos = parent->mem.free; in nxt_buf_parent_completion()
325 b->mem.free = nxt_cpymem(b->mem.free, i->mem.pos, nxt_buf_used_size(i)); in nxt_buf_make_plain()
H A Dnxt_conn_write.c13 static ssize_t nxt_sendfile(int fd, int s, off_t pos, size_t size);
245 nxt_sendfile(int fd, int s, off_t pos, size_t size) in nxt_sendfile() argument
253 int rc = sendfile(fd, s, pos, &sent, NULL, 0); in nxt_sendfile()
261 int rc = sendfile(fd, s, pos, size, NULL, &sent, 0); in nxt_sendfile()
267 res = sendfile(s, fd, &pos, size); in nxt_sendfile()
275 page_off = pos % nxt_pagesize; in nxt_sendfile()
278 pos - page_off); in nxt_sendfile()
H A Dnxt_fastcgi_source.c289 nxt_thread_log_debug("\"%*s\"", b->mem.free - b->mem.pos, in nxt_fastcgi_request_create()
290 b->mem.pos); in nxt_fastcgi_request_create()
308 nxt_thread_log_debug("\"%*s\"", b->mem.free - b->mem.pos, b->mem.pos); in nxt_fastcgi_request_create()
325 nxt_thread_log_debug("\"%*s\"", b->mem.free - b->mem.pos, b->mem.pos); in nxt_fastcgi_request_create()
425 for (p = b->mem.free - 1; p >= b->mem.pos; p--) { in nxt_fastcgi_source_record_filter()
431 size = (p + 1) - b->mem.pos; in nxt_fastcgi_source_record_filter()
436 size, b->mem.pos); in nxt_fastcgi_source_record_filter()
H A Dnxt_buf.h60 u_char *pos; member
117 ((b)->mem.pos != NULL)
202 ((bm)->free - (bm)->pos)
H A Dnxt_conn_proxy.c394 if (rb->mem.pos != rb->mem.free) { in nxt_conn_proxy_read_process()
405 wb->mem.pos = rb->mem.pos; in nxt_conn_proxy_read_process()
407 wb->mem.start = rb->mem.pos; in nxt_conn_proxy_read_process()
410 rb->mem.pos = rb->mem.free; in nxt_conn_proxy_read_process()
587 if (wb->mem.start != wb->mem.pos) { in nxt_conn_proxy_write_process()
598 rb->mem.pos = wb->mem.start; in nxt_conn_proxy_write_process()
601 rb->mem.end = wb->mem.pos; in nxt_conn_proxy_write_process()
603 wb->mem.start = wb->mem.pos; in nxt_conn_proxy_write_process()
608 if (wb->mem.pos != wb->mem.free) { in nxt_conn_proxy_write_process()
653 first->mem.pos = b->mem.start; in nxt_conn_proxy_read_add()
[all …]
H A Dnxt_h1proto_websocket.c150 nxt_memmove(in->mem.start, in->mem.pos, size); in nxt_h1p_websocket_frame_start()
152 in->mem.pos = in->mem.start; in nxt_h1p_websocket_frame_start()
245 wsh = (nxt_websocket_header_t *) c->read->mem.pos; in nxt_h1p_conn_ws_frame_header_read()
563 wsh = (nxt_websocket_header_t *) r->ws_frame->mem.pos; in nxt_h1p_conn_ws_frame_payload_read()
659 wsh = (nxt_websocket_header_t *) b->mem.pos; in nxt_h1p_conn_ws_pong()
662 b->mem.pos += 2; in nxt_h1p_conn_ws_pong()
664 nxt_memcpy(mask, b->mem.pos, 4); in nxt_h1p_conn_ws_pong()
666 b->mem.pos += 4; in nxt_h1p_conn_ws_pong()
694 *out->mem.free++ = *b->mem.pos++ ^ mask[i % 4]; in nxt_h1p_conn_ws_pong()
H A Dnxt_http_parse.h38 u_char **pos, const u_char *end);
98 u_char *pos; member
H A Dnxt_port_memory.c149 if (b->is_port_mmap_sent && b->mem.pos > b->mem.start) { in nxt_port_mmap_buf_completion()
154 p = b->mem.pos - 1; in nxt_port_mmap_buf_completion()
585 b->mem.pos = b->mem.start; in nxt_port_mmap_get_buf()
695 b->mem.pos = b->mem.start; in nxt_port_mmap_get_incoming_buf()
732 while (bmem && sb->iobuf[i].iov_base != bmem->mem.pos) { in nxt_port_mmap_write()
747 mmap_msg->chunk_id = nxt_port_mmap_chunk_id(hdr, bmem->mem.pos); in nxt_port_mmap_write()
775 mmap_msg = (nxt_port_mmap_msg_t *) b->mem.pos; in nxt_port_mmap_read()
797 b->mem.pos += sizeof(nxt_port_mmap_msg_t); in nxt_port_mmap_read()
H A Dnxt_http_source.c166 nxt_thread_log_debug("\"%*s\"", b->mem.free - b->mem.pos, in nxt_http_source_request_create()
167 b->mem.pos); in nxt_http_source_request_create()
180 nxt_thread_log_debug("\"%*s\"", b->mem.free - b->mem.pos, b->mem.pos); in nxt_http_source_request_create()
250 if (b->parent->mem.pos == b->parent->mem.end) { in nxt_http_source_status_filter()
252 b->mem.pos - b->mem.start, b->mem.start); in nxt_http_source_status_filter()
H A Dnxt_port.c245 msg = (nxt_port_msg_new_port_t *) b->mem.pos; in nxt_port_send_port()
268 new_port_msg = (nxt_port_msg_new_port_t *) msg->buf->mem.pos; in nxt_port_new_port_handler()
418 slot = *(nxt_uint_t *) b->mem.pos; in nxt_port_change_log_file_handler()
444 dump_size = b->mem.free - b->mem.pos; in nxt_port_data_handler()
450 nxt_debug(task, "data: %*s", dump_size, b->mem.pos); in nxt_port_data_handler()
511 nxt_memcpy(&pid, buf->mem.pos, sizeof(nxt_pid_t)); in nxt_port_remove_pid_handler()
H A Dnxt_buf_pool.c156 b->mem.pos = NULL; in nxt_buf_pool_free()
161 b->mem.pos = b->mem.start; in nxt_buf_pool_free()
/unit/test/unit/applications/
H A Dwebsockets.py200 pos = 0
202 while pos < frame_len:
203 end = min(pos + chopsize, frame_len)
205 sock.sendall(frame[pos:end])
208 pos = end
220 pos = 0
222 while pos < message_len:
223 end = min(pos + fragmention_size, message_len)
225 self.frame_write(sock, op_code, message[pos:end], fin=fin, **kwargs)
227 pos = end
/unit/src/ruby/
H A Dnxt_ruby.c897 pos = value; in nxt_ruby_hash_info()
900 pos = strchr(pos, '\n'); in nxt_ruby_hash_info()
909 pos++; in nxt_ruby_hash_info()
910 value = pos; in nxt_ruby_hash_info()
944 pos = value; in nxt_ruby_hash_add()
947 pos = strchr(pos, '\n'); in nxt_ruby_hash_add()
960 pos++; in nxt_ruby_hash_add()
961 value = pos; in nxt_ruby_hash_add()
1029 off_t pos; member
1047 file->pos += res; in nxt_ruby_rack_file_read()
[all …]

12