Skip to content

Commit 92d13a8

Browse files
JPeisachmtwebster
authored andcommitted
fix a null pointer deref scan-build found
1 parent 27c8b4a commit 92d13a8

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

libcinnamon-desktop/gnome-desktop-thumbnail.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -314,7 +314,7 @@ create_loader (GFile *file,
314314
loader = gdk_pixbuf_loader_new_with_mime_type (mime_type, &error);
315315
}
316316

317-
if (loader == NULL) {
317+
if (loader == NULL && error != NULL) {
318318
g_warning ("Unable to create loader for mime type %s: %s", mime_type, error->message);
319319
g_clear_error (&error);
320320
loader = gdk_pixbuf_loader_new ();

0 commit comments

Comments
 (0)