Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Handle m_processLauncher being null in ChildProcessProxy::processIden…
…tifier()

https://bugs.webkit.org/show_bug.cgi?id=167713
rdar://problem/28896113

Reviewed by Dan Bernstein.

This can happen if the process has been explicitly terminated.

* UIProcess/ChildProcessProxy.h:
(WebKit::ChildProcessProxy::processIdentifier):

Canonical link: https://commits.webkit.org/184779@main
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@211565 268f45cc-cd09-0410-ab3c-d52691b4dbfc
  • Loading branch information
Anders Carlsson committed Feb 2, 2017
1 parent e32e719 commit cf835e5
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 1 deletion.
13 changes: 13 additions & 0 deletions Source/WebKit2/ChangeLog
@@ -1,3 +1,16 @@
2017-02-01 Anders Carlsson <andersca@apple.com>

Handle m_processLauncher being null in ChildProcessProxy::processIdentifier()
https://bugs.webkit.org/show_bug.cgi?id=167713
rdar://problem/28896113

Reviewed by Dan Bernstein.

This can happen if the process has been explicitly terminated.

* UIProcess/ChildProcessProxy.h:
(WebKit::ChildProcessProxy::processIdentifier):

2017-02-02 Yongjun Zhang <yongjun_zhang@apple.com>

In iOS, we should take background assertion when accessing localstorage databases.
Expand Down
2 changes: 1 addition & 1 deletion Source/WebKit2/UIProcess/ChildProcessProxy.h
Expand Up @@ -71,7 +71,7 @@ class ChildProcessProxy : ProcessLauncher::Client, public IPC::Connection::Clien
};
State state() const;

pid_t processIdentifier() const { return m_processLauncher->processIdentifier(); }
pid_t processIdentifier() const { return m_processLauncher ? m_processLauncher->processIdentifier() : 0; }

bool canSendMessage() const { return state() != State::Terminated;}
bool sendMessage(std::unique_ptr<IPC::Encoder>, OptionSet<IPC::SendOption>);
Expand Down

0 comments on commit cf835e5

Please sign in to comment.