summaryrefslogtreecommitdiffstats
path: root/ext
diff options
context:
space:
mode:
Diffstat (limited to 'ext')
-rw-r--r--ext/dv/gstdvdemux.c4
-rw-r--r--ext/flac/gstflacdec.c2
-rw-r--r--ext/speex/gstspeexdec.c22
-rw-r--r--ext/speex/gstspeexenc.c4
4 files changed, 17 insertions, 15 deletions
diff --git a/ext/dv/gstdvdemux.c b/ext/dv/gstdvdemux.c
index e93d532c..5765aa30 100644
--- a/ext/dv/gstdvdemux.c
+++ b/ext/dv/gstdvdemux.c
@@ -516,7 +516,7 @@ gst_dvdemux_src_query (GstPad * pad, GstQuery * query)
break;
}
default:
- res = FALSE;
+ res = gst_pad_query_default (pad, query);
break;
}
gst_object_unref (dvdemux);
@@ -565,7 +565,7 @@ gst_dvdemux_sink_query (GstPad * pad, GstQuery * query)
break;
}
default:
- res = FALSE;
+ res = gst_pad_query_default (pad, query);
break;
}
gst_object_unref (dvdemux);
diff --git a/ext/flac/gstflacdec.c b/ext/flac/gstflacdec.c
index 836eadce..92aa4e2c 100644
--- a/ext/flac/gstflacdec.c
+++ b/ext/flac/gstflacdec.c
@@ -826,7 +826,7 @@ gst_flac_dec_src_query (GstPad * pad, GstQuery * query)
}
default:{
- res = FALSE;
+ res = gst_pad_query_default (pad, query);
break;
}
}
diff --git a/ext/speex/gstspeexdec.c b/ext/speex/gstspeexdec.c
index 5f68a32b..5bf95818 100644
--- a/ext/speex/gstspeexdec.c
+++ b/ext/speex/gstspeexdec.c
@@ -118,6 +118,7 @@ speex_get_query_types (GstPad * pad)
{
static const GstQueryType speex_dec_src_query_types[] = {
GST_QUERY_POSITION,
+ GST_QUERY_DURATION,
0
};
@@ -212,6 +213,7 @@ static gboolean
speex_dec_src_query (GstPad * pad, GstQuery * query)
{
GstSpeexDec *dec = GST_SPEEXDEC (GST_OBJECT_PARENT (pad));
+ gboolean res = FALSE;
switch (GST_QUERY_TYPE (query)) {
case GST_QUERY_POSITION:
@@ -221,10 +223,10 @@ speex_dec_src_query (GstPad * pad, GstQuery * query)
gst_query_parse_position (query, &format, NULL);
- speex_dec_convert (dec->srcpad, GST_FORMAT_DEFAULT, dec->samples_out,
- &format, &cur);
-
- gst_query_set_position (query, format, cur);
+ if ((res = speex_dec_convert (dec->srcpad, GST_FORMAT_DEFAULT,
+ dec->samples_out, &format, &cur))) {
+ gst_query_set_position (query, format, cur);
+ }
break;
}
case GST_QUERY_DURATION:
@@ -234,19 +236,19 @@ speex_dec_src_query (GstPad * pad, GstQuery * query)
gint64 total_samples;
if (!(peer = gst_pad_get_peer (dec->sinkpad)))
- return FALSE;
+ break;
gst_pad_query_duration (peer, &my_format, &total_samples);
gst_object_unref (peer);
- speex_dec_convert (dec->srcpad, GST_FORMAT_DEFAULT, total_samples,
- &my_format, &total_samples);
-
- gst_query_set_duration (query, GST_FORMAT_TIME, total_samples);
+ if ((res = speex_dec_convert (dec->srcpad, GST_FORMAT_DEFAULT,
+ total_samples, &my_format, &total_samples))) {
+ gst_query_set_duration (query, GST_FORMAT_TIME, total_samples);
+ }
break;
}
default:
- return FALSE;
+ res = gst_pad_query_default (pad, query);
break;
}
diff --git a/ext/speex/gstspeexenc.c b/ext/speex/gstspeexenc.c
index 7d6f3695..f3f680db 100644
--- a/ext/speex/gstspeexenc.c
+++ b/ext/speex/gstspeexenc.c
@@ -440,7 +440,7 @@ gst_speexenc_src_query (GstPad * pad, GstQuery * query)
break;
}
default:
- res = FALSE;
+ res = gst_pad_query_default (pad, query);
break;
}
@@ -473,7 +473,7 @@ gst_speexenc_sink_query (GstPad * pad, GstQuery * query)
break;
}
default:
- res = FALSE;
+ res = gst_pad_query_default (pad, query);
break;
}