|
|
@ -162,8 +162,13 @@ int ast_search_dns(void *context,
|
|
|
|
int res, ret = -1;
|
|
|
|
int res, ret = -1;
|
|
|
|
|
|
|
|
|
|
|
|
#ifdef linux
|
|
|
|
#ifdef linux
|
|
|
|
res_ninit(&dnsstate);
|
|
|
|
#ifndef __UCLIBC__
|
|
|
|
res = res_nsearch(&dnsstate, dname, class, type, answer, sizeof(answer));
|
|
|
|
res_ninit(&dnsstate);
|
|
|
|
|
|
|
|
res = res_nsearch(&dnsstate, dname, class, type, answer, sizeof(answer));
|
|
|
|
|
|
|
|
#else
|
|
|
|
|
|
|
|
res_init();
|
|
|
|
|
|
|
|
res = res_search(dname, class, type, answer, sizeof(answer));
|
|
|
|
|
|
|
|
#endif
|
|
|
|
#else
|
|
|
|
#else
|
|
|
|
res_init();
|
|
|
|
res_init();
|
|
|
|
res = res_search(dname, class, type, answer, sizeof(answer));
|
|
|
|
res = res_search(dname, class, type, answer, sizeof(answer));
|
|
|
@ -181,7 +186,11 @@ int ast_search_dns(void *context,
|
|
|
|
ret = 1;
|
|
|
|
ret = 1;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
#if defined(linux)
|
|
|
|
#if defined(linux)
|
|
|
|
res_nclose(&dnsstate);
|
|
|
|
#ifndef __UCLIBC__
|
|
|
|
|
|
|
|
res_nclose(&dnsstate);
|
|
|
|
|
|
|
|
#else
|
|
|
|
|
|
|
|
res_close();
|
|
|
|
|
|
|
|
#endif
|
|
|
|
#else
|
|
|
|
#else
|
|
|
|
#ifndef __APPLE__
|
|
|
|
#ifndef __APPLE__
|
|
|
|
res_close();
|
|
|
|
res_close();
|
|
|
|