зеркало из https://github.com/mozilla/gecko-dev.git
Bug 767779 - Stop eating animation frames for non-multipart. r=joe
This commit is contained in:
Родитель
5d1b19eb53
Коммит
2ad9f5fd2f
|
@ -1451,10 +1451,16 @@ RasterImage::AddSourceData(const char *aBuffer, PRUint32 aCount)
|
|||
// This call should come straight from necko - no reentrancy allowed
|
||||
NS_ABORT_IF_FALSE(!mInDecoder, "Re-entrant call to AddSourceData!");
|
||||
|
||||
// Image is already decoded, we shouldn't be getting data, but it could
|
||||
// be extra garbage data at the end of a file.
|
||||
if (mDecoded) {
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
// Starting a new part's frames, let's clean up before we add any
|
||||
// This needs to happen just before we start getting EnsureFrame() call(s),
|
||||
// so that there's no gap for anything to miss us.
|
||||
if (mBytesDecoded == 0) {
|
||||
if (mMultipart && mBytesDecoded == 0) {
|
||||
// Our previous state may have been animated, so let's clean up
|
||||
if (mAnimating) {
|
||||
StopAnimation();
|
||||
|
|
Загрузка…
Ссылка в новой задаче