summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorMax Kellermann <max@musicpd.org>2020-09-21 13:01:51 +0200
committerMax Kellermann <max@musicpd.org>2020-09-21 14:53:18 +0200
commit85849c93964161c15cc0cec7e68bb4917ee93bcd (patch)
tree86da2f7d606d26521012b5668e96975ea511b679 /test
parentd3c257d97d4ff7671f7761745fd3c5fd23fecc5f (diff)
decoder/plugin: add method protocols()
Similar to commit 4e2a551f30c1e1db13933d15c44d9186a2f37959 but for decoder plugins. This is tailored for the FFmpeg decoder plugin which implements some protocols (e.g. RTSP) as demuxer plugin.
Diffstat (limited to 'test')
-rw-r--r--test/run_decoder.cxx7
1 files changed, 6 insertions, 1 deletions
diff --git a/test/run_decoder.cxx b/test/run_decoder.cxx
index 1147e4faf..a7e275302 100644
--- a/test/run_decoder.cxx
+++ b/test/run_decoder.cxx
@@ -204,7 +204,12 @@ try {
}
MyDecoderClient client(c.seek_where);
- if (plugin->file_decode != nullptr) {
+ if (plugin->SupportsUri(c.uri)) {
+ try {
+ plugin->UriDecode(client, c.uri);
+ } catch (StopDecoder) {
+ }
+ } else if (plugin->file_decode != nullptr) {
try {
plugin->FileDecode(client, FromNarrowPath(c.uri));
} catch (StopDecoder) {