✨ feat(deps/utable): define kv in utable.h temporary
This commit is contained in:
@@ -13,17 +13,13 @@
|
||||
|
||||
#include "toml/toml.h"
|
||||
|
||||
struct module_manager *module_manager_new(const char *module_spec_toml_path, int max_thread_num, struct mq_schema *mq_schema, struct logger *logger)
|
||||
struct module_manager *module_manager_new(struct module_specification mod_specs[], size_t n_mod, int max_thread_num, struct mq_schema *mq_schema, struct logger *logger)
|
||||
{
|
||||
|
||||
struct module_manager *mod_mgr = CALLOC(struct module_manager, 1);
|
||||
mod_mgr->schema.max_thread_num=max_thread_num;
|
||||
mod_mgr->schema.mq_schema=mq_schema;
|
||||
mod_mgr->schema.logger=logger;
|
||||
if(module_spec_toml_path==NULL)return mod_mgr;
|
||||
FILE *fp = fopen(module_spec_toml_path, "r");
|
||||
if (fp == NULL)return mod_mgr;
|
||||
mod_mgr->module_spec_toml_path = strdup(module_spec_toml_path);
|
||||
|
||||
int mod_num = 0;
|
||||
toml_table_t *conf = toml_parse_file(fp, NULL, 0);
|
||||
|
||||
Reference in New Issue
Block a user