gst/: gcc 4.1 unreferenced pointer fixes.

Original commit message from CVS:
* gst/apetag/gsttagdemux.c: (gst_tag_demux_reset):
* gst/id3demux/gstid3demux.c: (gst_id3demux_reset):
* gst/wavparse/gstwavparse.c: (gst_wavparse_create_sourcepad),
(gst_wavparse_stream_headers), (gst_wavparse_send_event),
(gst_wavparse_change_state):
gcc 4.1 unreferenced pointer fixes.
This commit is contained in:
Edward Hervey 2006-03-21 14:53:36 +00:00
parent 0465903a85
commit 0186335dd2
4 changed files with 30 additions and 8 deletions

View file

@ -1,3 +1,12 @@
2006-03-21 Edward Hervey <edward@fluendo.com>
* gst/apetag/gsttagdemux.c: (gst_tag_demux_reset):
* gst/id3demux/gstid3demux.c: (gst_id3demux_reset):
* gst/wavparse/gstwavparse.c: (gst_wavparse_create_sourcepad),
(gst_wavparse_stream_headers), (gst_wavparse_send_event),
(gst_wavparse_change_state):
gcc 4.1 unreferenced pointer fixes.
2006-03-21 Tim-Philipp Müller <tim at centricular dot net>
Patch by: Tommi Myöhänen <ext-tommi dot myohanen at nokia dot com>

View file

@ -214,14 +214,17 @@ gst_tag_demux_class_init (gpointer klass, gpointer d)
static void
gst_tag_demux_reset (GstTagDemux * tagdemux)
{
GstBuffer **buffer_p = &tagdemux->priv->collect;
GstCaps **caps_p = &tagdemux->priv->src_caps;
tagdemux->priv->strip_start = 0;
tagdemux->priv->strip_end = 0;
tagdemux->priv->upstream_size = -1;
tagdemux->priv->state = GST_TAG_DEMUX_READ_START_TAG;
tagdemux->priv->send_tag_event = FALSE;
gst_buffer_replace (&(tagdemux->priv->collect), NULL);
gst_caps_replace (&(tagdemux->priv->src_caps), NULL);
gst_buffer_replace (buffer_p, NULL);
gst_caps_replace (caps_p, NULL);
gst_tag_demux_remove_srcpad (tagdemux);

View file

@ -182,14 +182,17 @@ gst_id3demux_class_init (GstID3DemuxClass * klass)
static void
gst_id3demux_reset (GstID3Demux * id3demux)
{
GstBuffer **buffer_p = &id3demux->collect;
GstCaps **caps_p = &id3demux->src_caps;
id3demux->strip_start = 0;
id3demux->strip_end = 0;
id3demux->upstream_size = -1;
id3demux->state = GST_ID3DEMUX_READID3V2;
id3demux->send_tag_event = FALSE;
gst_buffer_replace (&(id3demux->collect), NULL);
gst_caps_replace (&(id3demux->src_caps), NULL);
gst_buffer_replace (buffer_p, NULL);
gst_caps_replace (caps_p, NULL);
gst_id3demux_remove_srcpad (id3demux);

View file

@ -871,6 +871,7 @@ gst_wavparse_stream_headers (GstWavParse * wav)
GstCaps *caps;
gint64 duration;
gchar *codec_name = NULL;
GstEvent **event_p;
/* The header start with a 'fmt ' tag */
if ((res = gst_riff_read_chunk (GST_ELEMENT (wav), wav->sinkpad,
@ -987,7 +988,8 @@ gst_wavparse_stream_headers (GstWavParse * wav)
* the right newsegment event downstream. */
gst_wavparse_perform_seek (wav, wav->seek_event);
/* remove pending event */
gst_event_replace (&wav->seek_event, NULL);
event_p = &wav->seek_event;
gst_event_replace (event_p, NULL);
return GST_FLOW_OK;
@ -1066,6 +1068,7 @@ gst_wavparse_send_event (GstElement * element, GstEvent * event)
{
GstWavParse *wav = GST_WAVPARSE (element);
gboolean res = FALSE;
GstEvent **event_p;
switch (GST_EVENT_TYPE (event)) {
case GST_EVENT_SEEK:
@ -1075,7 +1078,8 @@ gst_wavparse_send_event (GstElement * element, GstEvent * event)
} else {
GST_DEBUG_OBJECT (wav, "queuing seek for later");
gst_event_replace (&wav->seek_event, event);
event_p = &wav->seek_event;
gst_event_replace (event_p, event);
/* we always return true */
res = TRUE;
@ -1517,10 +1521,13 @@ gst_wavparse_change_state (GstElement * element, GstStateChange transition)
switch (transition) {
case GST_STATE_CHANGE_PLAYING_TO_PAUSED:
break;
case GST_STATE_CHANGE_PAUSED_TO_READY:
case GST_STATE_CHANGE_PAUSED_TO_READY:{
GstEvent **event_p = &wav->seek_event;
gst_wavparse_destroy_sourcepad (wav);
gst_event_replace (&wav->seek_event, NULL);
gst_event_replace (event_p, NULL);
gst_wavparse_reset (wav);
}
break;
case GST_STATE_CHANGE_READY_TO_NULL:
break;