[webkit-help] How to Debug WebView termination

tenghu guo guotenghu at gmail.com
Mon Sep 13 22:47:13 PDT 2021


Hi, my app uses webview to render emails. However, some emails always lead
to webview termination. I want to dig into the root cause of the webview
termination.

I have successfully built and run the webkit in iOS simulator. However, the
webview never terminates in the simulator as the simulator has much more
resources(cpu/memory) than the actual device.
On the other hand, I can't run webkit on an actual device as "device builds
of WebKit cannot be installed on embedded devices." I have tried building
webkit source code on device, the error message is "error: Ad Hoc code
signing is not allowed with SDK 'iOS 15.0' (in target 'WebCoreTestShim'
from project 'WebCore')"

So here is my question,
1. How can I trigger webview termination in iOS simulator
1. Is there an approach to run webkit on an actual device?

I know webview is terminated because the UI process received a close
message from the web content process. I want to dig into why the web
content process is closed.

Below is the source code where I received the close message.

*void* WebProcessProxy::didClose(IPC::Connection& connection)

{

#if OS(DARWIN)

    WEBPROCESSPROXY_RELEASE_LOG_ERROR(Process, "didClose: (web process %d
crash)", connection.remoteProcessID());

#else

    WEBPROCESSPROXY_RELEASE_LOG_ERROR(Process, "didClose (web process
crash)");

#endif


    processDidTerminateOrFailedToLaunch(ProcessTerminationReason::Crash);

}
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-help/attachments/20210914/54d487fc/attachment.htm>


More information about the webkit-help mailing list