[gnome-software/gnome-3-26] plugin loader: Slightly increase warning timeouts



commit 1febb18bff8b18a75d8b6d37c22556d62b9ba619
Author: Kalev Lember <klember redhat com>
Date:   Sat Jan 27 11:52:05 2018 +0100

    plugin loader: Slightly increase warning timeouts
    
    Instead of 0.5 seconds, warn when a plugin takes longer than 1 second to
    run. We've had this warning for the appstream plugin for a while now
    during startup and it's just noise, hindering debugging / breaking in
    gdb on g_warnings.

 lib/gs-plugin-loader.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/lib/gs-plugin-loader.c b/lib/gs-plugin-loader.c
index f427ba9d..f74d7d18 100644
--- a/lib/gs-plugin-loader.c
+++ b/lib/gs-plugin-loader.c
@@ -765,7 +765,7 @@ gs_plugin_loader_call_vfunc (GsPluginLoaderHelper *helper,
        case GS_PLUGIN_ACTION_INITIALIZE:
        case GS_PLUGIN_ACTION_DESTROY:
        case GS_PLUGIN_ACTION_SETUP:
-               if (g_timer_elapsed (timer, NULL) > 0.5f) {
+               if (g_timer_elapsed (timer, NULL) > 1.0f) {
                        g_warning ("plugin %s took %.1f seconds to do %s",
                                   gs_plugin_get_name (plugin),
                                   g_timer_elapsed (timer, NULL),
@@ -773,7 +773,7 @@ gs_plugin_loader_call_vfunc (GsPluginLoaderHelper *helper,
                }
                break;
        default:
-               if (g_timer_elapsed (timer, NULL) > 0.5f) {
+               if (g_timer_elapsed (timer, NULL) > 1.0f) {
                        g_debug ("plugin %s took %.1f seconds to do %s",
                                 gs_plugin_get_name (plugin),
                                 g_timer_elapsed (timer, NULL),


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]