From 0021672451639e09d6860a849f95ec6c79adca0b Mon Sep 17 00:00:00 2001 From: Danny Mayer Date: Sun, 18 Nov 2001 03:03:42 +0000 Subject: [PATCH] Added proper code for retrieving the hostname --- bin/named/win32/os.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/bin/named/win32/os.c b/bin/named/win32/os.c index 646e679bda..2ea5e3ee31 100644 --- a/bin/named/win32/os.c +++ b/bin/named/win32/os.c @@ -15,7 +15,7 @@ * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: os.c,v 1.9 2001/10/12 05:40:41 marka Exp $ */ +/* $Id: os.c,v 1.10 2001/11/18 03:03:42 mayer Exp $ */ #include #include @@ -209,7 +209,9 @@ ns_os_shutdown(void) { isc_result_t ns_os_gethostname(char *buf, size_t len) { - UNUSED(buf); - UNUSED(len); - return (ISC_R_NOTIMPLEMENTED); + int n; + + n = gethostname(buf, len); + return ((n == 0) ? ISC_R_SUCCESS : ISC_R_FAILURE); } +