[Bug 797289] dispatch write never ends
GStreamer (GNOME Bugzilla)
bugzilla at gnome.org
Tue Oct 16 12:21:06 UTC 2018
https://bugzilla.gnome.org/show_bug.cgi?id=797289
--- Comment #4 from Göran Jönsson <goran.jonsson at axis.com> ---
>Ok so that needs a comment and reasoning in the code.
>
>In summary that means that a) when called from appsink we always send as much >as we can, and b) when called from the idle callback or the watch callback we >would first queue another idle probe.
OK I will do better comments about this.
>> You wrote:
>> "g_source_get_context() why? Shouldn't we attach to the main context of the
>> rtsp-server (from where the connection is used) here? "
>>
>> Answer:
>> The two context I have consider when doing this patch is the
>> * main context , but since there are a mutex involved I don't want to run
>> this on main thread.
>> * The context that handle dispatch write and dispatch read.
>> Is main context of the rtsp-server a third ? How can I get access to it ?
>See bottom of do_send_data(). You want to use priv->watch_context here >unconditionally.
I believe I do.
When reaching code line
g_source_attach (idle_src, g_source_get_context (current_src));
it can only be dispatch write or the new idle source that are calling.
They both run in same context. So
g_source_get_context (current_src) will give the same result as
priv->watch_context.
Please notice that in rtsp-stream there are no access to rtsp-client's
priv->watch_context .
--
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.
More information about the gstreamer-bugs
mailing list