Bug 102682

Summary: [EFL][WK2] Fix possible crash in EwkViewImpl::displayTimerFired()
Product: WebKit Reporter: Chris Dumez <cdumez>
Component: WebKit EFLAssignee: Chris Dumez <cdumez>
Status: RESOLVED FIXED    
Severity: Normal CC: d-r, gyuyoung.kim, kenneth, laszlo.gombos, lucas.de.marchi, ostap73, rakuco, tonikitoo, webkit.review.bot, yael
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch none

Description Chris Dumez 2012-11-19 05:36:33 PST
We sometimes get the following crash in EwkViewImpl::displayTimerFired():

1   0x411ed8
2   0x2b997e86acb0
3   0x2b997e6dd9f1 EwkViewImpl::displayTimerFired(WebCore::Timer<EwkViewImpl>*)
4   0x2b998122f8fa WebCore::ThreadTimers::sharedTimerFiredInternal()
5   0x2b9981b6f7fd
6   0x2b997ef1746e _ecore_timer_expired_call
7   0x2b997ef1763b _ecore_timer_expired_timers_call
8   0x2b997ef14551
9   0x2b997ef14b45 ecore_main_loop_iterate
10  0x411265 TestWebKitAPI::Util::run(bool*)
11  0x40ff15 TestWebKitAPI::WebKit2_DOMWindowExtensionNoCache_Test::TestBody()
12  0x2b997e7ee7ea testing::Test::Run()
13  0x2b997e7ee8f8 testing::internal::TestInfoImpl::Run()
14  0x2b997e7ee9b5 testing::TestCase::Run()
15  0x2b997e7eecee testing::internal::UnitTestImpl::RunAllTests()
16  0x4118a2 TestWebKitAPI::TestsController::run(int, char**)
17  0x4111d9 main
18  0x2b997fb2976d __libc_start_main
19  0x40f3e9

This is caused by the following line:
LayerTreeRenderer* renderer = page()->drawingArea()->layerTreeCoordinatorProxy()->layerTreeRenderer();

When the timer is fired, the drawingAreaProxy or the LayerTreeCoordinatorProxy may be NULL already so we need to check for it.
Comment 1 Chris Dumez 2012-11-19 05:40:11 PST
Created attachment 174962 [details]
Patch
Comment 2 WebKit Review Bot 2012-11-19 06:58:52 PST
Comment on attachment 174962 [details]
Patch

Clearing flags on attachment: 174962

Committed r135154: <http://trac.webkit.org/changeset/135154>
Comment 3 WebKit Review Bot 2012-11-19 06:58:56 PST
All reviewed patches have been landed.  Closing bug.
Comment 4 Yael 2012-11-19 08:17:46 PST
*** Bug 102222 has been marked as a duplicate of this bug. ***