From bb0d81fd4c9307c2b150ec9d28d57b34df009f0e Mon Sep 17 00:00:00 2001 From: Thibault Saunier Date: Sun, 3 May 2020 01:22:04 -0400 Subject: [PATCH] validate: Add details on all g_log message reports. Part-of: --- validate/gst/validate/gst-validate-report.c | 12 +++++++----- validate/gst/validate/gst-validate-runner.c | 6 ++++-- 2 files changed, 11 insertions(+), 7 deletions(-) diff --git a/validate/gst/validate/gst-validate-report.c b/validate/gst/validate/gst-validate-report.c index cd30dc13f9..2372c7e0bd 100644 --- a/validate/gst/validate/gst-validate-report.c +++ b/validate/gst/validate/gst-validate-report.c @@ -463,11 +463,13 @@ gst_validate_report_load_issues (void) _ ("Pad buffers push frequency is lower than the minimum required by the config"), NULL); - REGISTER_VALIDATE_ISSUE (WARNING, G_LOG_WARNING, _("We got a g_log warning"), - NULL); - REGISTER_VALIDATE_ISSUE (CRITICAL, G_LOG_CRITICAL, - "We got a g_log critical issue", NULL); - REGISTER_VALIDATE_ISSUE (ISSUE, G_LOG_ISSUE, "We got a g_log issue", NULL); + REGISTER_VALIDATE_ISSUE_FULL (WARNING, G_LOG_WARNING, + _("We got a g_log warning"), NULL, GST_VALIDATE_ISSUE_FLAGS_FULL_DETAILS); + REGISTER_VALIDATE_ISSUE_FULL (CRITICAL, G_LOG_CRITICAL, + "We got a g_log critical issue", NULL, + GST_VALIDATE_ISSUE_FLAGS_FULL_DETAILS); + REGISTER_VALIDATE_ISSUE_FULL (ISSUE, G_LOG_ISSUE, "We got a g_log issue", + NULL, GST_VALIDATE_ISSUE_FLAGS_FULL_DETAILS); REGISTER_VALIDATE_ISSUE (CRITICAL, PULL_RANGE_FROM_WRONG_THREAD, "gst_pad_pull_range called from wrong thread", diff --git a/validate/gst/validate/gst-validate-runner.c b/validate/gst/validate/gst-validate-runner.c index 386fee80f1..06d0a0f31d 100644 --- a/validate/gst/validate/gst-validate-runner.c +++ b/validate/gst/validate/gst-validate-runner.c @@ -764,13 +764,15 @@ _do_report_synthesis (GstValidateRunner * runner) if (report->level == GST_VALIDATE_REPORT_LEVEL_CRITICAL) { criticals = g_list_append (criticals, report); gst_validate_report_print_details (report); - } + } else if (report->issue->flags & GST_VALIDATE_ISSUE_FLAGS_FULL_DETAILS) + gst_validate_report_print_details (report); for (tmp = g_list_next (reports); tmp; tmp = tmp->next) { report = (GstValidateReport *) tmp->data; gst_validate_report_print_detected_on (report); - if (report->level == GST_VALIDATE_REPORT_LEVEL_CRITICAL) { + if ((report->level == GST_VALIDATE_REPORT_LEVEL_CRITICAL) || + (report->issue->flags & GST_VALIDATE_ISSUE_FLAGS_FULL_DETAILS)) { criticals = g_list_append (criticals, report); gst_validate_report_print_details (report); }