[gegl] bin/gegl.c: display a message and abort if the graph is invalid



commit deedc443a2c905e0d566a69aadbb432f5b1a93b8
Author: Michael Murà <batolettre gmail com>
Date:   Fri Sep 2 10:51:50 2011 +0200

    bin/gegl.c: display a message and abort if the graph is invalid

 bin/gegl.c |    6 ++++++
 1 files changed, 6 insertions(+), 0 deletions(-)
---
diff --git a/bin/gegl.c b/bin/gegl.c
index 708baf3..8af9881 100644
--- a/bin/gegl.c
+++ b/bin/gegl.c
@@ -185,6 +185,12 @@ main (gint    argc,
 
   gegl = gegl_node_new_from_xml (script, path_root);
 
+  if (!gegl)
+    {
+      g_print ("Invalid graph, abort.\n");
+      return;
+    }
+
   if (o->rest)
     {
       GeglNode *proxy;



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