From: Matt Watson Date: Tue, 22 Mar 2016 07:54:11 +0000 (-0700) Subject: animatedstyle: fail to create new style if timestamp goes backwards X-Git-Tag: archive/raspbian/4.4.1+ds1-2+rpi1^2~18^2~24^2~4967 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=6a88ac3b4cfa8a56f0bbcec66ecb05079d1a4ccd;p=gtk4.git animatedstyle: fail to create new style if timestamp goes backwards With slowdown factor, we will only we be able to handle timestamps that monotonically increase. --- diff --git a/gtk/gtkcssanimatedstyle.c b/gtk/gtkcssanimatedstyle.c index f0246e91cf..04337e54c2 100644 --- a/gtk/gtkcssanimatedstyle.c +++ b/gtk/gtkcssanimatedstyle.c @@ -467,6 +467,8 @@ gtk_css_animated_style_new_advance (GtkCssAnimatedStyle *source, if (timestamp == 0) return g_object_ref (source->style); + gtk_internal_return_val_if_fail (timestamp > source->current_time, NULL); + animations = NULL; for (l = source->animations; l; l = l->next) {