mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 1044498 - Return a null decoder when CreateSubDecoder is called in Shutdown state. r=cajbir
This commit is contained in:
parent
19b195a222
commit
f43aa33f3f
@ -344,6 +344,9 @@ CreateReaderForType(const nsACString& aType, AbstractMediaDecoder* aDecoder)
|
|||||||
already_AddRefed<SourceBufferDecoder>
|
already_AddRefed<SourceBufferDecoder>
|
||||||
MediaSourceReader::CreateSubDecoder(const nsACString& aType)
|
MediaSourceReader::CreateSubDecoder(const nsACString& aType)
|
||||||
{
|
{
|
||||||
|
if (IsShutdown()) {
|
||||||
|
return nullptr;
|
||||||
|
}
|
||||||
MOZ_ASSERT(GetTaskQueue());
|
MOZ_ASSERT(GetTaskQueue());
|
||||||
nsRefPtr<SourceBufferDecoder> decoder =
|
nsRefPtr<SourceBufferDecoder> decoder =
|
||||||
new SourceBufferDecoder(new SourceBufferResource(aType), mDecoder);
|
new SourceBufferDecoder(new SourceBufferResource(aType), mDecoder);
|
||||||
|
Loading…
Reference in New Issue
Block a user