Lines 1756-1762
static int init_by_resolv_conf(ares_channel channel)
Link Here
|
1756 |
|
1756 |
|
1757 |
if ((status == ARES_EOF) && (!channel->lookups)) { |
1757 |
if ((status == ARES_EOF) && (!channel->lookups)) { |
1758 |
/* Many systems (Solaris, Linux, BSD's) use nsswitch.conf */ |
1758 |
/* Many systems (Solaris, Linux, BSD's) use nsswitch.conf */ |
1759 |
fp = fopen("/etc/nsswitch.conf", "r"); |
1759 |
fp = fopen(SYSCONFDIR "/nsswitch.conf", "r"); |
1760 |
if (fp) { |
1760 |
if (fp) { |
1761 |
while ((status = ares__read_line(fp, &line, &linesize)) == |
1761 |
while ((status = ares__read_line(fp, &line, &linesize)) == |
1762 |
ARES_SUCCESS) |
1762 |
ARES_SUCCESS) |
Lines 1776-1782
static int init_by_resolv_conf(ares_channel channel)
Link Here
|
1776 |
DEBUGF(fprintf(stderr, "fopen() failed with error: %d %s\n", |
1776 |
DEBUGF(fprintf(stderr, "fopen() failed with error: %d %s\n", |
1777 |
error, strerror(error))); |
1777 |
error, strerror(error))); |
1778 |
DEBUGF(fprintf(stderr, "Error opening file: %s\n", |
1778 |
DEBUGF(fprintf(stderr, "Error opening file: %s\n", |
1779 |
"/etc/nsswitch.conf")); |
1779 |
SYSCONFDIR "/nsswitch.conf")); |
1780 |
} |
1780 |
} |
1781 |
|
1781 |
|
1782 |
/* ignore error, maybe we will get luck in next if clause */ |
1782 |
/* ignore error, maybe we will get luck in next if clause */ |