mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-04-26 06:54:49 +00:00
gst/mpegstream/gstmpegparse.c: Declare variables at the beginning of a block and make
Original commit message from CVS: * gst/mpegstream/gstmpegparse.c: (gst_mpeg_parse_pad_added), (gst_mpeg_parse_handle_src_query): Declare variables at the beginning of a block and make gcc-2.9x happy (fixes #328957; patch by: Jens Granseuer).
This commit is contained in:
parent
3de20e5147
commit
b06e084912
2 changed files with 12 additions and 3 deletions
|
@ -1,3 +1,10 @@
|
||||||
|
2006-03-01 Tim-Philipp Müller <tim at centricular dot net>
|
||||||
|
|
||||||
|
* gst/mpegstream/gstmpegparse.c: (gst_mpeg_parse_pad_added),
|
||||||
|
(gst_mpeg_parse_handle_src_query):
|
||||||
|
Declare variables at the beginning of a block and make
|
||||||
|
gcc-2.9x happy (fixes #328957; patch by: Jens Granseuer).
|
||||||
|
|
||||||
2006-03-01 Tim-Philipp Müller <tim at centricular dot net>
|
2006-03-01 Tim-Philipp Müller <tim at centricular dot net>
|
||||||
|
|
||||||
* gst/asfdemux/gstasfdemux.c: (gst_asf_demux_handle_data):
|
* gst/asfdemux/gstasfdemux.c: (gst_asf_demux_handle_data):
|
||||||
|
|
|
@ -455,6 +455,7 @@ static void
|
||||||
gst_mpeg_parse_pad_added (GstElement * element, GstPad * pad)
|
gst_mpeg_parse_pad_added (GstElement * element, GstPad * pad)
|
||||||
{
|
{
|
||||||
GstMPEGParse *mpeg_parse;
|
GstMPEGParse *mpeg_parse;
|
||||||
|
GstEvent *event;
|
||||||
|
|
||||||
if (GST_PAD_IS_SINK (pad)) {
|
if (GST_PAD_IS_SINK (pad)) {
|
||||||
return;
|
return;
|
||||||
|
@ -466,7 +467,7 @@ gst_mpeg_parse_pad_added (GstElement * element, GstPad * pad)
|
||||||
* the current time. This is required because MPEG allows any sort
|
* the current time. This is required because MPEG allows any sort
|
||||||
* of order of packets, and new substreams can be found at any
|
* of order of packets, and new substreams can be found at any
|
||||||
* time. */
|
* time. */
|
||||||
GstEvent *event = gst_event_new_new_segment (FALSE,
|
event = gst_event_new_new_segment (FALSE,
|
||||||
mpeg_parse->current_segment.rate,
|
mpeg_parse->current_segment.rate,
|
||||||
GST_FORMAT_TIME, mpeg_parse->current_segment.start,
|
GST_FORMAT_TIME, mpeg_parse->current_segment.start,
|
||||||
-1, mpeg_parse->current_segment.start);
|
-1, mpeg_parse->current_segment.start);
|
||||||
|
@ -1016,6 +1017,8 @@ gst_mpeg_parse_handle_src_query (GstPad * pad, GstQuery * query)
|
||||||
}
|
}
|
||||||
case GST_QUERY_POSITION:
|
case GST_QUERY_POSITION:
|
||||||
{
|
{
|
||||||
|
gint64 cur;
|
||||||
|
|
||||||
gst_query_parse_position (query, &format, NULL);
|
gst_query_parse_position (query, &format, NULL);
|
||||||
|
|
||||||
switch (format) {
|
switch (format) {
|
||||||
|
@ -1030,8 +1033,7 @@ gst_mpeg_parse_handle_src_query (GstPad * pad, GstQuery * query)
|
||||||
goto done;
|
goto done;
|
||||||
}
|
}
|
||||||
|
|
||||||
gint64 cur =
|
cur = (gint64) (mpeg_parse->current_scr) - mpeg_parse->first_scr;
|
||||||
(gint64) (mpeg_parse->current_scr) - mpeg_parse->first_scr;
|
|
||||||
src_value = MPEGTIME_TO_GSTTIME (MAX (0, cur));
|
src_value = MPEGTIME_TO_GSTTIME (MAX (0, cur));
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue