[gimp] Bug 664728 - XCF files with only one layer not loading properly



commit 0e901776e6d43ff861eb3603fe076d88423bb8f4
Author: Michael Natterer <mitch gimp org>
Date:   Mon Nov 28 01:32:49 2011 +0100

    Bug 664728 - XCF files with only one layer not loading properly
    
    In file_open_with_proc_and_display(), don't use the passed load_proc
    (which can be NULL) but the actually used load_proc to determine if
    the file was imported.

 app/file/file-open.c |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)
---
diff --git a/app/file/file-open.c b/app/file/file-open.c
index b662cf4..c192777 100644
--- a/app/file/file-open.c
+++ b/app/file/file-open.c
@@ -410,6 +410,9 @@ file_open_with_proc_and_display (Gimp                *gimp,
        * files. To solve this properly, we would need new file plug-in
        * API.
        */
+      if (! file_proc)
+        file_proc = gimp_image_get_load_proc (image);
+
       if (file_open_file_proc_is_import (file_proc) &&
           gimp_image_get_n_layers (image) == 1)
         {



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