"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "lib/dns.c" between
mailfromd-8.10.tar.xz and mailfromd-8.11.tar.xz

About: Mailfromd is a general-purpose mail filtering daemon for Sendmail, Postfix and MeTA1 (interfaces with the MTA using Milter or PMilter protocols).

dns.c  (mailfromd-8.10.tar.xz):dns.c  (mailfromd-8.11.tar.xz)
skipping to change at line 521 skipping to change at line 521
dns_status dns_status
ptr_lookup(struct in_addr ip, struct dns_reply *reply) ptr_lookup(struct in_addr ip, struct dns_reply *reply)
{ {
dns_status status = dns_failure; dns_status status = dns_failure;
int rc; int rc;
adns_answer *ans; adns_answer *ans;
char *name; char *name;
ip.s_addr = ntohl(ip.s_addr); ip.s_addr = ntohl(ip.s_addr);
mu_asprintf(&name, "%s.in-addr.arpa", inet_ntoa(ip)); mu_asprintf(&name, "%d.%d.%d.%d.in-addr.arpa",
ip.s_addr & 0xff,
(ip.s_addr >> 8) & 0xff,
(ip.s_addr >> 16) & 0xff,
(ip.s_addr >> 24) & 0xff);
rc = adns_synchronous(get_state(), name, adns_r_ptr_raw, rc = adns_synchronous(get_state(), name, adns_r_ptr_raw,
DEFAULT_QFLAGS, DEFAULT_QFLAGS,
&ans); &ans);
free(name); free(name);
if (rc) if (rc)
return errno_to_dns_status(rc); return errno_to_dns_status(rc);
status = adns_to_dns_status(ans->status); status = adns_to_dns_status(ans->status);
if (status == dns_success) { if (status == dns_success) {
int i; int i;
dns_reply_init(reply, dns_reply_str, ans->nrrs); dns_reply_init(reply, dns_reply_str, ans->nrrs);
 End of changes. 1 change blocks. 
1 lines changed or deleted 5 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)