Changeset 213448 in webkit


Ignore:
Timestamp:
Mar 6, 2017 6:19:40 AM (7 years ago)
Author:
magomez@igalia.com
Message:

[GTK] WebProcess from WebKitGtk+ 2.15.x SIGSEVs in GIFLZWContext::doLZW(unsigned char const*, unsigned long) at Source/WebCore/platform/image-decoders/gif/GIFImageReader.cpp:303
https://bugs.webkit.org/show_bug.cgi?id=167304

Reviewed by Carlos Garcia Campos.

Add a lock to ensure that the GIFImageReader that we are using for decoding is not deleted while
the decoding thread is using it.

No new tests.

  • platform/image-decoders/gif/GIFImageDecoder.cpp:

(WebCore::GIFImageDecoder::clearFrameBufferCache):

Location:
trunk/Source/WebCore
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r213446 r213448  
     12017-03-06  Miguel Gomez  <magomez@igalia.com>
     2
     3        [GTK] WebProcess from WebKitGtk+ 2.15.x SIGSEVs in GIFLZWContext::doLZW(unsigned char const*, unsigned long) at Source/WebCore/platform/image-decoders/gif/GIFImageReader.cpp:303
     4        https://bugs.webkit.org/show_bug.cgi?id=167304
     5
     6        Reviewed by Carlos Garcia Campos.
     7
     8        Add a lock to ensure that the GIFImageReader that we are using for decoding is not deleted while
     9        the decoding thread is using it.
     10
     11        No new tests.
     12
     13        * platform/image-decoders/gif/GIFImageDecoder.cpp:
     14        (WebCore::GIFImageDecoder::clearFrameBufferCache):
     15
    1162017-03-06  Antti Koivisto  <antti@apple.com>
    217
  • trunk/Source/WebCore/platform/image-decoders/gif/GIFImageDecoder.cpp

    r210501 r213448  
    134134        return; // Nothing to do.
    135135
     136    // Lock the decodelock here, as we are going to destroy the GIFImageReader and doing so while
     137    // there's an ongoing decode will cause a crash.
     138    LockHolder locker(m_decodeLock);
     139
    136140    // The "-1" here is tricky.  It does not mean that |clearBeforeFrame| is the
    137141    // last frame we wish to preserve, but rather that we never want to clear
Note: See TracChangeset for help on using the changeset viewer.