[Webkit-unassigned] [Bug 33213] Make png image decoder work with segmented SharedBuffer

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Wed Jan 6 10:57:05 PST 2010


https://bugs.webkit.org/show_bug.cgi?id=33213





--- Comment #14 from Yong Li <yong.li.webkit at gmail.com>  2010-01-06 10:57:05 PST ---
Darin, there's a bug in yesterday's commit for png decoder:

I move "if (!m_hasFinishedDecoding && decoder->isAllDataReceived())" out of the
loop, but it hurts another "break".

        while (unsigned segmentLength = data.getSomeData(segment,
m_readOffset)) {
            m_readOffset += segmentLength;
            m_currentBufferSize = m_readOffset;
            png_process_data(m_png, m_info,
reinterpret_cast<png_bytep>(const_cast<char*>(segment)), segmentLength);
            if ((sizeOnly && decoder->isSizeAvailable()) ||
m_hasFinishedDecoding)
                break;
        }
        if (!m_hasFinishedDecoding && decoder->isAllDataReceived())
            decoder->pngComplete();

When "sizeonly" is true, decoder->pngComplete() shouldn't be called.

Should I post a patch in this bug, or raise a new bug?(In reply to comment #13)
> Patch in this bug is fine. r=me in advance on adding sizeOnly to the if
> condition, so you don't need to post a patch at all if that's what you do.

Peter Kasting already raised a bug for it. bug 33258

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list