config: move debug/log configuration to the new API

This commit is contained in:
Nardi Ivan
2024-01-18 10:21:24 +01:00
committed by Ivan Nardi
parent c704be1a20
commit 6c85f10cd5
18 changed files with 106 additions and 104 deletions
+2 -4
View File
@@ -37,14 +37,12 @@ void fuzz_set_alloc_callbacks_and_seed(int seed)
void fuzz_init_detection_module(struct ndpi_detection_module_struct **ndpi_info_mod)
{
NDPI_PROTOCOL_BITMASK all;
NDPI_PROTOCOL_BITMASK debug_bitmask;
if(*ndpi_info_mod == NULL) {
*ndpi_info_mod = ndpi_init_detection_module();
NDPI_BITMASK_SET_ALL(debug_bitmask);
ndpi_set_log_level(*ndpi_info_mod, 4);
ndpi_set_debug_bitmask(*ndpi_info_mod, debug_bitmask);
ndpi_set_config(*ndpi_info_mod, NULL, "log.level", "3");
ndpi_set_config(*ndpi_info_mod, "all", "log.enable", "1");
ndpi_load_categories_dir(*ndpi_info_mod, "./lists/");
ndpi_load_protocols_file(*ndpi_info_mod, "protos.txt");