⚠ Archived content — this site is no longer maintained.   Current WebKit documentation is at docs.webkit.org.

Changeset 118655 in webkit


Ignore:
Timestamp:
May 28, 2012, 1:53:45 AM (14 years ago)
Author:
commit-queue@webkit.org
Message:

[BlackBerry] http authentication crash the browser when user commit or cancel the http authentication dialog
https://bugs.webkit.org/show_bug.cgi?id=87579

Patch by Jonathan Dong <Jonathan Dong> on 2012-05-28
Reviewed by George Staikos.

In function NetworkJob::startNewJobWithRequest, We should cancel the
NetworkJob first before we start a new NetworkJob which reuses the
resource handle of the old one. If we only set the m_handle = 0 of the
old NetworkJob without cancelling itself, it will still receives data
notification from network thread and handles the received data with
the released resource handler, which will cause the crash.

No new tests because no behavior has changed.

  • platform/network/blackberry/NetworkJob.cpp:

(WebCore::NetworkJob::startNewJobWithRequest):

Location:
trunk/Source/WebCore
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r118654 r118655  
     12012-05-28  Jonathan Dong  <jonathan.dong@torchmobile.com.cn>
     2
     3        [BlackBerry] http authentication crash the browser when user commit or cancel the http authentication dialog
     4        https://bugs.webkit.org/show_bug.cgi?id=87579
     5
     6        Reviewed by George Staikos.
     7
     8        In function NetworkJob::startNewJobWithRequest, We should cancel the
     9        NetworkJob first before we start a new NetworkJob which reuses the
     10        resource handle of the old one. If we only set the m_handle = 0 of the
     11        old NetworkJob without cancelling itself, it will still receives data
     12        notification from network thread and handles the received data with
     13        the released resource handler, which will cause the crash.
     14
     15        No new tests because no behavior has changed.
     16
     17        * platform/network/blackberry/NetworkJob.cpp:
     18        (WebCore::NetworkJob::startNewJobWithRequest):
     19
    1202012-05-27  MORITA Hajime  <morrita@google.com>
    221
  • trunk/Source/WebCore/platform/network/blackberry/NetworkJob.cpp

    r117246 r118655  
    529529    // Pass the ownership of the ResourceHandle to the new NetworkJob.
    530530    RefPtr<ResourceHandle> handle = m_handle;
    531     m_handle = 0;
    532     m_multipartResponse = nullptr;
     531    cancelJob();
    533532
    534533    NetworkManager::instance()->startJob(m_playerId,
Note: See TracChangeset for help on using the changeset viewer.