diff options
Diffstat (limited to 'src/rost.c')
-rw-r--r-- | src/rost.c | 22 |
1 files changed, 12 insertions, 10 deletions
@@ -275,31 +275,33 @@ int main(int argc, char **argv) set_log_verbosity(verbosity); - /* - if (!load_all_core_components(false)) + if (!load_all_core_components(true)) goto done; - */ /* Traitement des recherches */ scanner = g_content_scanner_new_from_file(rules); - content = g_file_content_new(target); + if (scanner != NULL) + { + content = g_file_content_new(target); + + context = g_content_scanner_analyze(scanner, options, content); - context = g_content_scanner_analyze(scanner, options, content); + g_scan_context_display(context); - g_scan_context_display(context); + g_object_unref(G_OBJECT(context)); + g_object_unref(G_OBJECT(content)); - g_object_unref(G_OBJECT(context)); - g_object_unref(G_OBJECT(content)); + g_object_unref(G_OBJECT(scanner)); - g_object_unref(G_OBJECT(scanner)); + } g_object_unref(G_OBJECT(options)); /* Sortie */ - //unload_all_core_components(false); + unload_all_core_components(false); #ifdef TRACK_GOBJECT_LEAKS remember_gtypes_for_leaks(); |