Changeset 5981 for pjproject/trunk/pjlib-util/src/pjlib-util/srv_resolver.c
- Timestamp:
- May 9, 2019 4:54:38 AM (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
pjproject/trunk/pjlib-util/src/pjlib-util/srv_resolver.c
r5635 r5981 686 686 status = pj_dns_parse_addr_response(pkt, &rec); 687 687 if (status!=PJ_SUCCESS) { 688 char errmsg[PJ_ERR_MSG_SIZE]; 689 690 PJ_LOG(4,(query_job->objname, 691 "DNS %s record parse error for '%.*s'." 692 " Err=%d (%s)", 693 (is_type_a ? "A" : "AAAA"), 694 (int)query_job->domain_part.slen, 695 query_job->domain_part.ptr, 696 status, 697 pj_strerror(status,errmsg,sizeof(errmsg)).ptr)); 688 PJ_PERROR(4,(query_job->objname, status, 689 "DNS %s record parse error for '%.*s'.", 690 (is_type_a ? "A" : "AAAA"), 691 (int)query_job->domain_part.slen, 692 query_job->domain_part.ptr)); 698 693 } 699 694 } … … 756 751 757 752 } else if (status != PJ_SUCCESS) { 758 char errmsg[PJ_ERR_MSG_SIZE];759 760 753 /* Update last error */ 761 754 query_job->last_error = status; 762 755 763 756 /* Log error */ 764 pj_strerror(status, errmsg, sizeof(errmsg)); 765 PJ_LOG(4,(query_job->objname, 766 "DNS %s record resolution failed: %s", 767 (is_type_a? "A" : "AAAA"), 768 errmsg)); 757 PJ_PERROR(4,(query_job->objname, status, 758 "DNS %s record resolution failed", 759 (is_type_a? "A" : "AAAA"))); 769 760 } 770 761 … … 841 832 /* Check for failure */ 842 833 if (status != PJ_SUCCESS) { 843 char errmsg[PJ_ERR_MSG_SIZE]; 844 PJ_UNUSED_ARG(errmsg); 845 PJ_LOG(4,(query_job->objname, 846 "DNS %s record resolution error for '%.*s'." 847 " Err=%d (%s)", 848 pj_dns_get_type_name(query_job->dns_state), 849 (int)query_job->domain_part.slen, 850 query_job->domain_part.ptr, 851 status, 852 pj_strerror(status,errmsg,sizeof(errmsg)).ptr)); 834 PJ_PERROR(4,(query_job->objname, status, 835 "DNS %s record resolution error for '%.*s'.", 836 pj_dns_get_type_name(query_job->dns_state), 837 (int)query_job->domain_part.slen, 838 query_job->domain_part.ptr)); 853 839 854 840 /* Cancel any pending query */
Note: See TracChangeset
for help on using the changeset viewer.