Bug 80782

Summary: Web Inspector: Crash using released frontendClient when resizing window with closed inspector
Product: WebKit Reporter: Joseph Pecoraro <joepeck>
Component: Web Inspector (Deprecated)Assignee: Nobody <webkit-unassigned>
Status: RESOLVED FIXED    
Severity: Normal CC: apavlov, bweinstein, joepeck, keishi, loislo, pfeldman, pmuellr, rik, timothy, webkit.review.bot, yurys
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: All   
OS: All   
Attachments:
Description Flags
[PATCH] Clear Weak Pointers when Frontend is Closed
none
[PATCH] Clear Weak Pointers when Frontend is Closed (With ASSERTs) none

Joseph Pecoraro
Reported 2012-03-11 00:37:19 PST
* STEPS TO REPRODUCE 1. Open 1st Inspector. 2. Inspect Inspector (opens 2nd inspector) 3. Close 2nd inspector. 4. Resize 1st Inspector. => CRASH. Log below Thread 0 Crashed:: Dispatch queue: com.apple.main-thread 0 WebCore::InspectorController::inspectedPage() const + 4 (InspectorController.cpp:314) 1 WebCore::InspectorFrontendClientLocal::canAttachWindow() + 19 (OwnPtr.h:57) 2 WebKit::WebInspector::updateDockingAvailability() + 30 (WebInspector.cpp:236) 3 WebCore::FrameView::layout(bool) + 2483 (FrameView.cpp:1128) 4 WebCore::FrameView::updateLayoutAndStyleIfNeededRecursive() + 128 (HashTable.h:327) 5 WebKit::WebPage::layoutIfNeeded() + 34 (RefPtr.h:72) Patch to follow.
Attachments
[PATCH] Clear Weak Pointers when Frontend is Closed (3.05 KB, patch)
2012-03-11 00:42 PST, Joseph Pecoraro
no flags
[PATCH] Clear Weak Pointers when Frontend is Closed (With ASSERTs) (3.29 KB, patch)
2012-03-11 00:53 PST, Joseph Pecoraro
no flags
Joseph Pecoraro
Comment 1 2012-03-11 00:42:20 PST
Created attachment 131207 [details] [PATCH] Clear Weak Pointers when Frontend is Closed • I named the new function destroyInspectorPage for lack of a better name. It balances createInspectorPage. • This matches the WK1 side, which clears its weak references when handling closeInspectorFrontend
Joseph Pecoraro
Comment 2 2012-03-11 00:53:54 PST
Created attachment 131208 [details] [PATCH] Clear Weak Pointers when Frontend is Closed (With ASSERTs) I added asserts in WebInspector::createInspectorPage that these values are null. What was happening before was that these values were just getting stale and overwritten.
WebKit Review Bot
Comment 3 2012-03-11 03:12:07 PDT
Comment on attachment 131208 [details] [PATCH] Clear Weak Pointers when Frontend is Closed (With ASSERTs) Clearing flags on attachment: 131208 Committed r110390: <http://trac.webkit.org/changeset/110390>
WebKit Review Bot
Comment 4 2012-03-11 03:12:12 PDT
All reviewed patches have been landed. Closing bug.
Note You need to log in before you can comment on or make changes to this bug.