diff options
author | Olivier CrĂȘte <olivier.crete@collabora.com> | 2012-09-11 20:30:55 -0400 |
---|---|---|
committer | Olivier CrĂȘte <olivier.crete@collabora.com> | 2012-09-11 20:30:55 -0400 |
commit | 9b559160cc30c796031d7794caafea008d4b5a8a (patch) | |
tree | a07768285e6f7f03b79cb91c6d7c6638d88b1f7d | |
parent | f9320170cd85a1c3443ae6fabd78e7605e1ec903 (diff) |
spanplc: Don't unref too much, don't forward gap event
-rw-r--r-- | ext/spandsp/gstspanplc.c | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/ext/spandsp/gstspanplc.c b/ext/spandsp/gstspanplc.c index 4025e4fa7..73a2465b2 100644 --- a/ext/spandsp/gstspanplc.c +++ b/ext/spandsp/gstspanplc.c @@ -222,7 +222,6 @@ static gboolean gst_span_plc_event_sink (GstPad * pad, GstObject * parent, GstEvent * event) { GstSpanPlc *plc = GST_SPAN_PLC (parent); - gboolean ret = FALSE; GST_DEBUG_OBJECT (plc, "received event %s", GST_EVENT_TYPE_NAME (event)); @@ -241,7 +240,8 @@ gst_span_plc_event_sink (GstPad * pad, GstObject * parent, GstEvent * event) gst_event_parse_gap (event, ×tamp, &duration); gst_span_plc_send_fillin (plc, timestamp, duration); - break; + gst_event_unref (event); + return TRUE; } case GST_EVENT_FLUSH_STOP: gst_span_plc_flush (plc, TRUE); @@ -249,9 +249,6 @@ gst_span_plc_event_sink (GstPad * pad, GstObject * parent, GstEvent * event) default: break; } - ret = gst_pad_push_event (plc->srcpad, event); - - gst_object_unref (plc); - return ret; + return gst_pad_push_event (plc->srcpad, event); } |