diff --git a/src/daemon/collectd.c b/src/daemon/collectd.c
index 8573579166ab7e0aa13078d934ec92ffbf30324e..c9e49f8070536e8d1b99044c74fa0352b7c40178 100644 (file)
--- a/src/daemon/collectd.c
+++ b/src/daemon/collectd.c
int status;
str = global_option_get ("Hostname");
- if (str != NULL)
+ if ((str != NULL) && (str[0] != 0))
{
sstrncpy (hostname_g, str, sizeof (hostname_g));
return (0);
* something wrong.
*/
if (init_global_variables () != 0)
- return (1);
+ exit (EXIT_FAILURE);
if (test_config)
return (0);