Bug 138500 - WTR crashes after running a test when NetworkProcess enabled
Summary: WTR crashes after running a test when NetworkProcess enabled
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Tools / Tests (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Nobody
URL:
Keywords:
Depends on:
Blocks: 138428
  Show dependency treegraph
 
Reported: 2014-11-07 02:29 PST by Carlos Garcia Campos
Modified: 2014-11-08 02:47 PST (History)
3 users (show)

See Also:


Attachments
Patch (1.52 KB, patch)
2014-11-07 02:33 PST, Carlos Garcia Campos
ap: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Carlos Garcia Campos 2014-11-07 02:29:45 PST
Program received signal SIGSEGV, Segmentation fault.
0x00007ffff53b0b38 in WebKit::WebNotificationManagerProxy::initializeProvider(WKNotificationProviderBase const*) ()
   from WebKitBuild/Release/lib/libwebkit2gtk-4.0.so.37
(gdb) bt
#0  0x00007ffff53b0b38 in WebKit::WebNotificationManagerProxy::initializeProvider(WKNotificationProviderBase const*) ()
   from WebKitBuild/Release/lib/libwebkit2gtk-4.0.so.37
#1  0x0000000000418476 in WTR::WebNotificationProvider::~WebNotificationProvider() ()
#2  0x000000000040fc33 in WTR::TestController::~TestController() ()
#3  0x000000000040c250 in main ()

I don't know why it only happens with the network process enabled, though. The thing is that WebNotificationProvider destructor is calling WKNotificationManagerSetProvider, but m_notificationManager is null because removeNotificationManager was already called.
Comment 1 Carlos Garcia Campos 2014-11-07 02:33:01 PST
Created attachment 241170 [details]
Patch
Comment 2 Alexey Proskuryakov 2014-11-07 16:48:08 PST
Comment on attachment 241170 [details]
Patch

This seems OK to do.

The difference is that on Mac, WebContext is destroyed after WebNotificationProvider, so removeNotificationManager is never called.
Comment 3 Carlos Garcia Campos 2014-11-08 02:47:13 PST
Committed r175774: <http://trac.webkit.org/changeset/175774>