From: Enlightenment S. <no-...@en...> - 2011-11-05 12:04:41
|
Log: emotion: fix recursive call. Author: cedric Date: 2011-11-05 05:04:34 -0700 (Sat, 05 Nov 2011) New Revision: 64756 Trac: http://trac.enlightenment.org/e/changeset/64756 Modified: trunk/emotion/src/modules/gstreamer/emotion_sink.c Modified: trunk/emotion/src/modules/gstreamer/emotion_sink.c =================================================================== --- trunk/emotion/src/modules/gstreamer/emotion_sink.c 2011-11-05 11:58:41 UTC (rev 64755) +++ trunk/emotion/src/modules/gstreamer/emotion_sink.c 2011-11-05 12:04:34 UTC (rev 64756) @@ -699,10 +699,14 @@ if (!priv || !priv->o || priv->unlocked) goto exit_point; + if (send->ev->send) + { + emotion_gstreamer_buffer_free(send->ev->send); + send->ev->send = NULL; + } + if (!send->ev->stream && !send->force) { - if (send->ev->send) - emotion_gstreamer_buffer_free(send->ev->send); send->ev->send = send; goto exit_stream; } @@ -822,7 +826,7 @@ if (!ev->stream && !send->force) { - if (ev->send) + if (ev->send && send != ev->send) emotion_gstreamer_buffer_free(ev->send); ev->send = send; evas_object_image_data_update_add(priv->o, 0, 0, priv->width, priv->height); @@ -1121,12 +1125,14 @@ _video_update_pixels(void *data, Evas_Object *obj __UNUSED__, const Evas_Video_Surface *surface __UNUSED__) { Emotion_Gstreamer_Video *ev = data; + Emotion_Gstreamer_Buffer *send; if (!ev->send) return ; - ev->send->force = EINA_TRUE; - evas_video_sink_main_render(ev->send); + send = ev->send; + send->force = EINA_TRUE; ev->send = NULL; + evas_video_sink_main_render(send); } GstElement * |