X-Git-Url: http://git.tuebingen.mpg.de/?p=dss.git;a=blobdiff_plain;f=dss.c;h=258cd3fe862054298f078e6815d152bdd56f162d;hp=4202d08da8c0eeee0a567da6db239a5865beed6b;hb=024b342374b97ce23ac35f4ff7da146f1088d94b;hpb=66cdd5bc99a53d2b408a6cdc2d501fe27f9db13b diff --git a/dss.c b/dss.c index 4202d08..258cd3f 100644 --- a/dss.c +++ b/dss.c @@ -24,14 +24,14 @@ #include "gcc-compat.h" #include "cmdline.h" #include "log.h" -#include "string.h" -#include "error.h" -#include "fd.h" +#include "str.h" +#include "err.h" +#include "file.h" #include "exec.h" #include "daemon.h" -#include "signal.h" +#include "sig.h" #include "df.h" -#include "time.h" +#include "tv.h" #include "snap.h" #include "ipc.h" @@ -932,8 +932,9 @@ static int check_config(void) return -E_INVALID_NUMBER; } DSS_DEBUG_LOG(("unit interval: %i day(s)\n", conf.unit_interval_arg)); - if (conf.num_intervals_arg <= 0) { - DSS_ERROR_LOG(("bad number of intervals %i\n", conf.num_intervals_arg)); + if (conf.num_intervals_arg <= 0 || conf.num_intervals_arg > 30) { + DSS_ERROR_LOG(("bad number of intervals: %i\n", + conf.num_intervals_arg)); return -E_INVALID_NUMBER; } DSS_DEBUG_LOG(("number of intervals: %i\n", conf.num_intervals_arg));