From: Nick Bowler Date: Thu, 11 Feb 2010 13:53:56 +0000 (-0500) Subject: lbxgui: Fix an error handling regression. X-Git-Url: https://git.draconx.ca/gitweb/liblbx.git/commitdiff_plain/c44fd73cfd97f75ebfba25abe766b44f9d0346d2 lbxgui: Fix an error handling regression. If the framebuffer allocation fails, it still gets passed to render_to_pixbuf. This causes an assertion failure. --- diff --git a/src/gui/lbxgui.c b/src/gui/lbxgui.c index 2c1235a..9e462e6 100644 --- a/src/gui/lbxgui.c +++ b/src/gui/lbxgui.c @@ -63,7 +63,7 @@ void set_frame(GtkSpinButton *spin, gpointer data) { unsigned frame = gtk_spin_button_get_value_as_int(spin); - if (image) + if (image && framebuf) render_to_pixbuf(image, framebuf, frame); gdk_window_invalidate_rect(canvas->window, NULL, FALSE); }