Make resuming of decoding work for anonymous decoders.

This commit is contained in:
wolfbeast 2019-01-21 13:58:20 +01:00 committed by Roy Tam
commit f84fdea422
3 changed files with 18 additions and 7 deletions

View file

@ -126,7 +126,7 @@ ImageOps::DecodeToSurface(nsIInputStream* aInputStream,
}
// Run the decoder synchronously.
RefPtr<IDecodingTask> task = new AnonymousDecodingTask(WrapNotNull(decoder));
RefPtr<IDecodingTask> task = new AnonymousDecodingTask(WrapNotNull(decoder), /* aResumable */ false);
task->Run();
if (!decoder->GetDecodeDone() || decoder->HasError()) {
return nullptr;