[gegl/soc-2013-n-point-deformation] operations: don't crash if bump-map's aux is NULL



commit f0fcb3442dd75153ec020e12556b363d69157ca1
Author: Michael Natterer <mitch gimp org>
Date:   Thu Jun 27 22:30:37 2013 +0200

    operations: don't crash if bump-map's aux is NULL

 operations/common/bump-map.c |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)
---
diff --git a/operations/common/bump-map.c b/operations/common/bump-map.c
index ed1810f..e30a3a4 100644
--- a/operations/common/bump-map.c
+++ b/operations/common/bump-map.c
@@ -313,6 +313,9 @@ process (GeglOperation       *operation,
   // This should be made more sophisticated
   int has_alpha = (channels == 4) || (channels == 2);
 
+  if (! aux)
+    return FALSE;
+
   bm_width = gegl_buffer_get_width (aux);
   bm_height = gegl_buffer_get_height (aux);
 


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