diff options
author | Matthias Clasen <mclasen@redhat.com> | 2005-01-23 04:35:09 +0000 |
---|---|---|
committer | Matthias Clasen <matthiasc@src.gnome.org> | 2005-01-23 04:35:09 +0000 |
commit | a66dd6b37d816144dd89de0e28ebb72e298d5c5d (patch) | |
tree | 6a777eba6badbd0f5ec03ca6cdc3d1177ddc9ee0 /gdk-pixbuf | |
parent | a7f083932d413ada67a3cd8b638f8e3cd74cfcca (diff) | |
download | gdk-pixbuf-a66dd6b37d816144dd89de0e28ebb72e298d5c5d.tar.gz |
Close the loader before unreffing it in the error case. (#164915, Crispin
2005-01-22 Matthias Clasen <mclasen@redhat.com>
* gdk-pixbuf-loader.c (gdk_pixbuf_loader_new_with_type)
(gdk_pixbuf_loader_new_with_mime_type): Close the loader
before unreffing it in the error case. (#164915, Crispin
Flowerday)
Diffstat (limited to 'gdk-pixbuf')
-rw-r--r-- | gdk-pixbuf/ChangeLog | 7 | ||||
-rw-r--r-- | gdk-pixbuf/gdk-pixbuf-loader.c | 4 |
2 files changed, 10 insertions, 1 deletions
diff --git a/gdk-pixbuf/ChangeLog b/gdk-pixbuf/ChangeLog index db00ecc44..aba989854 100644 --- a/gdk-pixbuf/ChangeLog +++ b/gdk-pixbuf/ChangeLog @@ -1,3 +1,10 @@ +2005-01-22 Matthias Clasen <mclasen@redhat.com> + + * gdk-pixbuf-loader.c (gdk_pixbuf_loader_new_with_type) + (gdk_pixbuf_loader_new_with_mime_type): Close the loader + before unreffing it in the error case. (#164915, Crispin + Flowerday) + 2005-01-12 Owen Taylor <otaylor@redhat.com> * Makefile.am: Use grep | head -n 1 instead of grep -m 1 diff --git a/gdk-pixbuf/gdk-pixbuf-loader.c b/gdk-pixbuf/gdk-pixbuf-loader.c index 9e252c570..bccee9fc7 100644 --- a/gdk-pixbuf/gdk-pixbuf-loader.c +++ b/gdk-pixbuf/gdk-pixbuf-loader.c @@ -564,6 +564,7 @@ gdk_pixbuf_loader_new_with_type (const char *image_type, if (tmp != NULL) { g_propagate_error (error, tmp); + gdk_pixbuf_loader_close (retval, NULL); g_object_unref (retval); return NULL; } @@ -619,10 +620,11 @@ gdk_pixbuf_loader_new_with_mime_type (const char *mime_type, retval = g_object_new (GDK_TYPE_PIXBUF_LOADER, NULL); tmp = NULL; - gdk_pixbuf_loader_load_module(retval, image_type, &tmp); + gdk_pixbuf_loader_load_module (retval, image_type, &tmp); if (tmp != NULL) { g_propagate_error (error, tmp); + gdk_pixbuf_loader_close (retval, NULL); g_object_unref (retval); return NULL; } |