uuid plugin: Fixed hostname setting
authorPavel Rochnyack <pavel2000@ngs.ru>
Thu, 29 Mar 2018 18:27:14 +0000 (01:27 +0700)
committerPavel Rochnyack <pavel2000@ngs.ru>
Thu, 29 Mar 2018 18:30:37 +0000 (01:30 +0700)
Closes: #2723
References: #2467

src/uuid.c

index 4846841..1cb9027 100644 (file)
@@ -193,7 +193,7 @@ static int uuid_init(void) {
   char *uuid = uuid_get_local();
 
   if (uuid) {
-    sstrncpy(hostname_g, uuid, DATA_MAX_NAME_LEN);
+    hostname_set(uuid);
     sfree(uuid);
     return 0;
   }