Changeset 5536 for pjproject/trunk/pjlib-util/src/pjlib-util/srv_resolver.c
- Timestamp:
- Jan 23, 2017 1:34:12 AM (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
pjproject/trunk/pjlib-util/src/pjlib-util/srv_resolver.c
r5471 r5536 653 653 } else if (query_job->dns_state == PJ_DNS_TYPE_A) { 654 654 pj_bool_t is_type_a, srv_completed; 655 pj_dns_addr_record rec; 655 656 656 657 /* Clear outstanding job */ … … 669 670 is_type_a = (common->type == PJ_DNS_TYPE_A); 670 671 672 /* Parse response */ 673 if (status==PJ_SUCCESS && pkt->hdr.anscount != 0) { 674 status = pj_dns_parse_addr_response(pkt, &rec); 675 if (status!=PJ_SUCCESS) { 676 char errmsg[PJ_ERR_MSG_SIZE]; 677 678 PJ_LOG(4,(query_job->objname, 679 "DNS %s record parse error for '%.*s'." 680 " Err=%d (%s)", 681 (is_type_a ? "A" : "AAAA"), 682 (int)query_job->domain_part.slen, 683 query_job->domain_part.ptr, 684 status, 685 pj_strerror(status,errmsg,sizeof(errmsg)).ptr)); 686 } 687 } 688 671 689 /* Check that we really have answer */ 672 690 if (status==PJ_SUCCESS && pkt->hdr.anscount != 0) { 673 691 char addr[PJ_INET6_ADDRSTRLEN]; 674 pj_dns_addr_record rec;675 676 /* Parse response */677 status = pj_dns_parse_addr_response(pkt, &rec);678 if (status != PJ_SUCCESS)679 goto on_error;680 692 681 693 pj_assert(rec.addr_count != 0);
Note: See TracChangeset
for help on using the changeset viewer.