From fea7eeb543d7bbdb4bbc95dffc9f69154da6f15d Mon Sep 17 00:00:00 2001 From: octo Date: Fri, 14 Apr 2006 15:27:31 +0000 Subject: [PATCH] Fixing compile-errors/-warnings when building without librrd. --- src/common.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/common.c b/src/common.c index 7690d019..58db4d8a 100644 --- a/src/common.c +++ b/src/common.c @@ -363,7 +363,8 @@ static int check_create_dir (const char *file_orig) /* * * * * * Magic * * * * * */ -int rra_get (char ***ret) +#if HAVE_LIBRRD +static int rra_get (char ***ret) { static char **rra_def = NULL; static int rra_num = 0; @@ -440,12 +441,16 @@ int rra_get (char ***ret) *ret = rra_def; return (rra_num); } +#endif /* HAVE_LIBRRD */ static int log_create_file (char *filename, char **ds_def, int ds_num) { FILE *log; int i; + if (check_create_dir (filename)) + return (-1); + log = fopen (filename, "w"); if (log == NULL) { -- 2.30.2