[gegl] introspect: avoid crashing on NULL node argument



commit fe09dadcb1fc9ab119c6c5b00cf2cea5cd760c33
Author: Øyvind Kolås <pippin gimp org>
Date:   Sun Mar 12 22:46:56 2017 +0100

    introspect: avoid crashing on NULL node argument

 operations/common/introspect.c |    5 ++++-
 1 files changed, 4 insertions(+), 1 deletions(-)
---
diff --git a/operations/common/introspect.c b/operations/common/introspect.c
index b7178d8..b6334d1 100644
--- a/operations/common/introspect.c
+++ b/operations/common/introspect.c
@@ -46,7 +46,7 @@ gegl_introspect_load_cache (GeglProperties *op_introspect)
   gchar      *dot_filename = NULL;
   gchar      *dot_cmd      = NULL;
 
-  if (op_introspect->user_data)
+  if (op_introspect->user_data || op_introspect->node == NULL)
     return;
 
   /* Construct temp filenames */
@@ -130,6 +130,9 @@ gegl_introspect_process (GeglOperation        *operation,
 
   gegl_introspect_load_cache (o);
 
+  if (!o->user_data)
+    return FALSE;
+
   /* gegl_operation_context_take_object() takes the reference we have,
    * so we must increase it since we want to keep the object
    */


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