From 36f2b6dd696a5a491da875fa47f5363c178b491c Mon Sep 17 00:00:00 2001 From: Jean Sirmai Date: Mon, 23 Sep 2024 11:01:12 +0200 Subject: [PATCH] journal using SPEW (instead of REPETITIVE) --- include/fsm.h | 2 +- src/fsm/dispatch.c | 6 +++--- src/signal.c | 10 +++++----- src/widget/one_rule/algebra/conditions.c | 2 +- 4 files changed, 10 insertions(+), 10 deletions(-) diff --git a/include/fsm.h b/include/fsm.h index 03ce888..a491bf7 100644 --- a/include/fsm.h +++ b/include/fsm.h @@ -62,7 +62,7 @@ typedef struct disp_list {int value; struct disp_list *suiv;} disp_list ; * * * * * - J O U R N A L M E T A R U L E S - * * * */ -enum severity {CRITICAL, ERROR, WARNING, INFO, MESSAGE, DEBUG, REPETITIVE, SPEW}; +enum severity {CRITICAL, ERROR, WARNING, INFO, MESSAGE, DEBUG, SPEW}; enum source { SOURCE, TARGET, JOURNAL, FSM, PREFER, diff --git a/src/fsm/dispatch.c b/src/fsm/dispatch.c index d5553bc..d65d638 100644 --- a/src/fsm/dispatch.c +++ b/src/fsm/dispatch.c @@ -60,8 +60,8 @@ static journal gg_logs; void fsm_journal_publication_request () {fsm_journal_publish (gg_logs);} -// CRITICAL ERROR WARNING INFO MESSAGE DEBUG REPETITIVE SPEW -// 0 1 2 3 4 5 6 7 +// CRITICAL ERROR WARNING INFO MESSAGE DEBUG SPEW (bye bye REPETITIVE 2024-09-23) +// 0 1 2 3 4 5 6 void fsm_journal_event (int severity, int source, const char *file_source, @@ -70,7 +70,7 @@ void fsm_journal_event (int severity, { if ( // TRUE // just to find easily the line beginning the filter conditions 😄️ - severity != REPETITIVE + severity < SPEW // source != TREE // source == FSM // strcmp (value, "") diff --git a/src/signal.c b/src/signal.c index 7470d5d..666caae 100644 --- a/src/signal.c +++ b/src/signal.c @@ -72,7 +72,7 @@ static void on_user_tree_expander_toggled (GtkExpander *expander, void on_setup_user_tree_factory (GtkSignalListItemFactory *factory, GObject* object, gpointer user_data){ - fsm_journal_event (REPETITIVE, EXPANDER, "signal", "setup user tree factory()", ""); + fsm_journal_event (SPEW, EXPANDER, "signal", "setup user tree factory()", ""); GtkWidget* expander = gtk_expander_new (NULL); gtk_list_item_set_child (GTK_LIST_ITEM (object), expander); } @@ -101,7 +101,7 @@ void on_bind_user_tree_factory (GtkSignalListItemFactory *factory, row); gtk_widget_set_margin_start (expander, gtk_tree_list_row_get_depth(row) * 20); - fsm_journal_event (REPETITIVE, TREE, "signal", "(tree) bind user tree factory()", text); + fsm_journal_event (SPEW, TREE, "signal", "(tree) bind user tree factory()", text); } @@ -200,13 +200,13 @@ void on_axis_value_change (GtkAdjustment *adjustment, gpointer data) char string_value [10]; sprintf(string_value, " (%d)", axis_value); switch (axis) { - case 0 : fsm_journal_event (REPETITIVE, SLIDER_X, + case 0 : fsm_journal_event (SPEW, SLIDER_X, "signal", "X value changed()", string_value); break; - case 1 : fsm_journal_event (REPETITIVE, SLIDER_Y, + case 1 : fsm_journal_event (SPEW, SLIDER_Y, "signal", "Y value changed()", string_value); break; - case 2 : fsm_journal_event (REPETITIVE, SLIDER_Z, + case 2 : fsm_journal_event (SPEW, SLIDER_Z, "signal", "Z value changed()", string_value); break; } diff --git a/src/widget/one_rule/algebra/conditions.c b/src/widget/one_rule/algebra/conditions.c index 32c01f7..103f1d5 100644 --- a/src/widget/one_rule/algebra/conditions.c +++ b/src/widget/one_rule/algebra/conditions.c @@ -56,7 +56,7 @@ void *widget_get_btt_conditions_list() char str6[4]; sprintf(str6, "%d)", rand() % 10); one_condition = concat (str1, str2, str3, str4, str5, str6, NULL); widget_set_item_text (list_box, one_condition, TRUE); - fsm_journal_event (REPETITIVE, + fsm_journal_event (SPEW, RULE_CONDITION, "one_rule/algebra/conditions", "conditions list ",