X-Git-Url: https://git.tokkee.org/?a=blobdiff_plain;f=src%2Fconfigfile.c;h=40b46fab2d9fb160639ddf24956fd8263c60ade8;hb=c9596f6cf39a128c10764c3091e6a28186be2303;hp=39265868eac9dfb3eee7e2c79221c5be2c92c4d2;hpb=00432825e8e65164957c337fb29b3dd7b5133b8d;p=collectd.git diff --git a/src/configfile.c b/src/configfile.c index 39265868..40b46fab 100644 --- a/src/configfile.c +++ b/src/configfile.c @@ -258,6 +258,27 @@ static int cf_callback_mode (const char *shortvar, const char *var, operating_mode = MODE_SERVER; else if (strcasecmp (value, "Local") == 0) operating_mode = MODE_LOCAL; +#else /* !HAVE_LIBRRD */ + else if (strcasecmp (value, "Server") == 0) + { + fprintf (stderr, "Invalid mode `Server': " + "You need to link against librrd for this " + "mode to be available.\n"); + syslog (LOG_ERR, "Invalid mode `Server': " + "You need to link against librrd for this " + "mode to be available."); + return (LC_CBRET_ERROR); + } + else if (strcasecmp (value, "Local") == 0) + { + fprintf (stderr, "Invalid mode `Local': " + "You need to link against librrd for this " + "mode to be available.\n"); + syslog (LOG_ERR, "Invalid mode `Local': " + "You need to link against librrd for this " + "mode to be available."); + return (LC_CBRET_ERROR); + } #endif else if (strcasecmp (value, "Log") == 0) operating_mode = MODE_LOG;