Lines Matching refs:pos
70 uint16_t pos, uint16_t len) in set_dns_msg_response() argument
73 dns_msg->response_position = pos; in set_dns_msg_response()
114 uint16_t pos; in dns_unpack_answer() local
154 pos = dns_msg->answer_offset + dname_len + in dns_unpack_answer()
164 set_dns_msg_response(dns_msg, DNS_RESPONSE_IP, pos, len); in dns_unpack_answer()
169 pos, len); in dns_unpack_answer()
362 struct dns_msg_t *dns_msg, uint16_t pos) in dns_copy_qname() argument
372 if (pos >= msg_size) { in dns_copy_qname()
377 lb_size = msg[pos]; in dns_copy_qname()
383 if (pos + 1 >= msg_size) { in dns_copy_qname()
389 pos = ((msg[pos] & mask) << 8) + msg[pos + 1]; in dns_copy_qname()
397 if (DNS_LABEL_LEN_SIZE + lb_size > MIN(size - *len, msg_size - pos)) { in dns_copy_qname()
403 memcpy(buf + *len, msg + pos, DNS_LABEL_LEN_SIZE + lb_size); in dns_copy_qname()
407 pos += DNS_LABEL_LEN_SIZE + lb_size; in dns_copy_qname()
483 int pos; in dns_unpack_name() local
496 pos = ((val & 0x3f) << 8) | (*curr_src & 0xff); in dns_unpack_name()
498 curr_src = msg + pos; in dns_unpack_name()