summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/util/util.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/util/util.c b/lib/util/util.c
index 7548d30b7e..40ac7f79e6 100644
--- a/lib/util/util.c
+++ b/lib/util/util.c
@@ -206,6 +206,7 @@ _PUBLIC_ char *get_myname(void)
/* get my host name */
if (gethostname(hostname, MAXHOSTNAMELEN+1) == -1) {
DEBUG(0,("gethostname failed\n"));
+ free(hostname);
return NULL;
}