decoder/Client: add OpenUri(), replacing decoder_open_uri()

This commit is contained in:
Max Kellermann
2016-11-18 12:34:04 +01:00
parent 1a8c96a3f0
commit 723e54f74e
7 changed files with 18 additions and 21 deletions

View File

@@ -251,14 +251,11 @@ Decoder::SeekError()
}
InputStreamPtr
decoder_open_uri(DecoderClient &client, const char *uri)
Decoder::OpenUri(const char *uri)
{
auto &decoder = (Decoder &)client;
assert(dc.state == DecoderState::START ||
dc.state == DecoderState::DECODE);
assert(decoder.dc.state == DecoderState::START ||
decoder.dc.state == DecoderState::DECODE);
DecoderControl &dc = decoder.dc;
Mutex &mutex = dc.mutex;
Cond &cond = dc.cond;