st: Fix crash in theme-node-transition
Setting up the framebuffers for transitions may fail, in which case the material used for drawing is left uninitialized, so trying to access it results in a crash. Instead bail out in this case, which means that we won't paint anything during the transition - still, drawing errors are better than crashes ... https://bugzilla.gnome.org/show_bug.cgi?id=659676
This commit is contained in:
parent
40c5db397d
commit
8bd5b1e696
@ -328,6 +328,9 @@ st_theme_node_transition_paint (StThemeNodeTransition *transition,
|
|||||||
|
|
||||||
calculate_offscreen_box (transition, allocation);
|
calculate_offscreen_box (transition, allocation);
|
||||||
priv->needs_setup = !setup_framebuffers (transition, allocation);
|
priv->needs_setup = !setup_framebuffers (transition, allocation);
|
||||||
|
|
||||||
|
if (priv->needs_setup) /* setting up framebuffers failed */
|
||||||
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
cogl_color_set_from_4f (&constant, 0., 0., 0.,
|
cogl_color_set_from_4f (&constant, 0., 0., 0.,
|
||||||
|
Loading…
Reference in New Issue
Block a user