[gimp] Bug 656471 - GIMP crashes when File > Properties



commit b74c7d0ff602c27a6eb7fbcf2d6a25ccf6eab89c
Author: Martin Nordholts <martinn src gnome org>
Date:   Sat Aug 13 23:03:03 2011 +0200

    Bug 656471 - GIMP crashes when File > Properties

 app/pdb/image-cmds.c       |    4 +++-
 tools/pdbgen/pdb/image.pdb |    4 +++-
 2 files changed, 6 insertions(+), 2 deletions(-)
---
diff --git a/app/pdb/image-cmds.c b/app/pdb/image-cmds.c
index 231ad3f..378e234 100644
--- a/app/pdb/image-cmds.c
+++ b/app/pdb/image-cmds.c
@@ -2102,7 +2102,9 @@ image_get_filename_invoker (GimpProcedure      *procedure,
 
   if (success)
     {
-      filename = g_filename_from_uri (gimp_image_get_any_uri (image), NULL, NULL);
+      const gchar *uri = gimp_image_get_any_uri (image);
+      if (uri)
+        filename = g_filename_from_uri (uri, NULL, NULL);
     }
 
   return_vals = gimp_procedure_get_return_values (procedure, success,
diff --git a/tools/pdbgen/pdb/image.pdb b/tools/pdbgen/pdb/image.pdb
index 4edcdb1..6bc1d91 100644
--- a/tools/pdbgen/pdb/image.pdb
+++ b/tools/pdbgen/pdb/image.pdb
@@ -2099,7 +2099,9 @@ HELP
     %invoke = (
         code => <<'CODE'
 {
-  filename = g_filename_from_uri (gimp_image_get_any_uri (image), NULL, NULL);
+  const gchar *uri = gimp_image_get_any_uri (image);
+  if (uri)
+    filename = g_filename_from_uri (uri, NULL, NULL);
 }
 CODE
     );



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