mirror of
https://github.com/isc-projects/bind9.git
synced 2026-06-10 20:29:59 -04:00
[v9_9] silence "unused value" warning
(cherry picked from commit f4d20b15a2)
This commit is contained in:
parent
182d657891
commit
1b3a9c2755
1 changed files with 6 additions and 1 deletions
|
|
@ -169,6 +169,9 @@ isc_dir_chdir(const char *dirname) {
|
|||
|
||||
isc_result_t
|
||||
isc_dir_chroot(const char *dirname) {
|
||||
#ifdef HAVE_CHROOT
|
||||
void *tmp;
|
||||
#endif
|
||||
|
||||
REQUIRE(dirname != NULL);
|
||||
|
||||
|
|
@ -179,7 +182,9 @@ isc_dir_chroot(const char *dirname) {
|
|||
* may fail to load library in chroot.
|
||||
* Do not report errors if it fails, we do not need any result now.
|
||||
*/
|
||||
getprotobyname("udp") && getservbyname("domain", "udp");
|
||||
tmp = getprotobyname("udp");
|
||||
if (tmp != NULL)
|
||||
(void) getservbyname("domain", "udp");
|
||||
|
||||
if (chroot(dirname) < 0 || chdir("/") < 0)
|
||||
return (isc__errno2result(errno));
|
||||
|
|
|
|||
Loading…
Reference in a new issue