gst/videoparse/gstvideoparse.c: Free the adapter on dispose and correctly reset on newsegment events.

Original commit message from CVS:
* gst/videoparse/gstvideoparse.c: (gst_video_parse_dispose),
(gst_video_parse_sink_event):
Free the adapter on dispose and correctly reset on newsegment events.
This commit is contained in:
Sebastian Dröge 2007-12-15 17:52:46 +00:00
parent 00ec95f3d2
commit cd9b0d7168
3 changed files with 17 additions and 2 deletions

View file

@ -1,3 +1,9 @@
2007-12-15 Sebastian Dröge <slomo@circular-chaos.org>
* gst/videoparse/gstvideoparse.c: (gst_video_parse_dispose),
(gst_video_parse_sink_event):
Free the adapter on dispose and correctly reset on newsegment events.
2007-12-15 Sebastian Dröge <slomo@circular-chaos.org>
* gst/videoparse/gstvideoparse.c: (gst_video_parse_sink_event),

2
common

@ -1 +1 @@
Subproject commit ea5f2cfab1a164a5d285fe745343cbe0a476a904
Subproject commit a00d4c1966aab517c2694c61d580489ebcbce448

View file

@ -337,7 +337,12 @@ gst_video_parse_init (GstVideoParse * vp, GstVideoParseClass * g_class)
static void
gst_video_parse_dispose (GObject * object)
{
//GstVideoParse *vp = GST_VIDEO_PARSE (object);
GstVideoParse *vp = GST_VIDEO_PARSE (object);
if (vp->adapter) {
g_object_unref (vp->adapter);
vp->adapter = NULL;
}
G_OBJECT_CLASS (parent_class)->dispose (object);
}
@ -725,6 +730,10 @@ gst_video_parse_sink_event (GstPad * pad, GstEvent * event)
ret = gst_pad_push_event (vp->srcpad, event);
}
vp->n_frames = 0;
vp->discont = TRUE;
gst_adapter_clear (vp->adapter);
break;
}
default: