completely avoid usage of strnlen()

This commit is contained in:
Christian Kruse
2014-03-06 18:08:10 +01:00
committed by Jaime Casanova
parent 1c67e105ff
commit 24bd4e7a3f
4 changed files with 2 additions and 18 deletions

View File

@@ -140,7 +140,7 @@ parse_config(const char *config_file, t_configuration_options * options)
fclose(fp);
/* Check config settings */
if (strnlen(options->cluster_name, MAXLEN) == 0)
if (*options->cluster_name == '\0')
{
log_err(_("Cluster name is missing. Check the configuration file.\n"));
exit(ERR_BAD_CONFIG);