Fix memory corruption in the GIF decoder if a GIF specified a frame with no pixel data.  When creating the subsequent frame, we'd try and copy this frame's data, assuming it was sized properly, when in fact we'd allocated no space; then writing pixel data into this buffer overwrote whatever was sitting in memory.

Basically, we need to ensure that every frame gets properly initialized (sized, allocated, and data copied or cleared as appropriate) before we move to the next frame.  Since we can't rely on haveDecodedRow() getting called for all frames, we now also initialize as needed in frameComplete().

BUG=5573
Review URL: http://codereview.chromium.org/14168

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@7103 0039d316-1c4b-4281-b951-d872f2087c98
1 file changed