[sysprof/wip/chergert/sysprof-3] libsysprof: cancel if we fail auth



commit f998dd455e4196329f241897332f7a265578b05c
Author: Christian Hergert <chergert redhat com>
Date:   Fri May 10 14:58:34 2019 -0700

    libsysprof: cancel if we fail auth
    
    To not do this would leave us in a very bad loop asking for too many
    pieces of information.

 src/libsysprof/sysprof-local-profiler.c | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)
---
diff --git a/src/libsysprof/sysprof-local-profiler.c b/src/libsysprof/sysprof-local-profiler.c
index ddae50e..238bbe9 100644
--- a/src/libsysprof/sysprof-local-profiler.c
+++ b/src/libsysprof/sysprof-local-profiler.c
@@ -481,8 +481,11 @@ sysprof_local_profiler_authorize_cb (GObject      *object,
   g_assert (G_IS_ASYNC_RESULT (result));
   g_assert (SYSPROF_IS_LOCAL_PROFILER (self));
 
-  /* Ignore the result and try anyway */
-  sysprof_helpers_authorize_finish (helpers, result, NULL);
+  if (!sysprof_helpers_authorize_finish (helpers, result, &error))
+    {
+      sysprof_profiler_emit_failed (SYSPROF_PROFILER (self), error);
+      return;
+    }
 
   if (priv->writer == NULL)
     {


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