Code

Added support for more than one TypesDB file.
[collectd.git] / src / types_list.c
index 002761ce3e7a76568df04612058d1492825595d2..43e87902efda3a0c54dc056dfc0e5e8b9ed8d157 100644 (file)
@@ -169,17 +169,12 @@ static void parse_file (FILE *fh)
   } /* while (fgets) */
 } /* void parse_file */
 
-int read_types_list (void)
+int read_types_list (const char *file)
 {
-  const char *file;
   FILE *fh;
 
-  file = global_option_get ("TypesDB");
   if (file == NULL)
-  {
-    ERROR ("global_option_get (\"TypesDB\") returned NULL.");
     return (-1);
-  }
 
   fh = fopen (file, "r");
   if (fh == NULL)