GNOME Bugzilla – Bug 756252
Resurrect NetSim
Last modified: 2016-05-06 08:50:34 UTC
Created attachment 312917 [details] [review] implementation with tests Found and ported to 1.6
Review of attachment 312917 [details] [review]: ::: gst/netsim/gstnetsim.c @@ +88,3 @@ + GST_STATIC_CAPS_ANY); + +G_DEFINE_TYPE (GstNetSim, gst_net_sim, GST_TYPE_ELEMENT); I do believe this element could benefit from being a GstBaseTransform based.
(In reply to Nicolas Dufresne (stormer) from comment #1) > Review of attachment 312917 [details] [review] [review]: > > ::: gst/netsim/gstnetsim.c > @@ +88,3 @@ > + GST_STATIC_CAPS_ANY); > + > +G_DEFINE_TYPE (GstNetSim, gst_net_sim, GST_TYPE_ELEMENT); > > I do believe this element could benefit from being a GstBaseTransform based. Given that the push happens in a different thread to the chain, I am not sure this is ideal for BaseTransform. Do you have any examples of BaseTransform being used in an element where buffer input and output happens in different threads?
That is a fair argument, a fact I didn't notice as I didn't yet read it. There is a bug about creating (or enhancing current) a BaseTransform base class for that. I don't believe it should block this from being merged imho.
Created attachment 320937 [details] [review] updated patch Rebased to latest master with a few more fixes
commit e3f9e854f08e82bfab11182c5a2aa6f9a0c73cd5 Author: Stian Selnes <stian@pexip.com> Date: Wed Oct 7 23:49:58 2015 +0200 netsim: Add netsim element Resurrected from the Farstream repository and given an overhaul to fix races, deadlocks etc. https://bugzilla.gnome.org/show_bug.cgi?id=756252
Just got this btw, you happen to have a fix for that already? :) nexpected critical/warning: gstpad.c:4156:gst_pad_chain_data_unchecked:<netsim0:sink> Got data flow before stream-start event 50%: Checks: 2, Failures: 1, Errors: 0 gstcheck.c:79:F:general:netsim_stress:0: Unexpected critical/warning: gstpad.c:4156:gst_pad_chain_data_unchecked:<netsim0:sink> Got data flow before stream-start event FAIL elements/netsim (exit status: 1) Hard to reproduce here though.