Bug 161322 - Stop using WebProcessProxy::fromConnection in WebPageProxy
Summary: Stop using WebProcessProxy::fromConnection in WebPageProxy
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: New Bugs (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Anders Carlsson
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-08-29 12:39 PDT by Anders Carlsson
Modified: 2016-08-29 12:46 PDT (History)
0 users

See Also:


Attachments
Patch (2.96 KB, patch)
2016-08-29 12:40 PDT, Anders Carlsson
mitz: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Anders Carlsson 2016-08-29 12:39:49 PDT
Stop using WebProcessProxy::fromConnection in WebPageProxy
Comment 1 Anders Carlsson 2016-08-29 12:40:23 PDT
Created attachment 287308 [details]
Patch
Comment 2 Darin Adler 2016-08-29 12:42:45 PDT
Comment on attachment 287308 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=287308&action=review

> Source/WebKit2/ChangeLog:8
> +        The WebPageProxy alreayd knows its WebProcessProxy - no need to look it up from the connection.

Typo: already misspelled.

> Source/WebKit2/UIProcess/WebPageProxy.cpp:672
> +    ASSERT(m_process->connection() == &connection);

Is there a solid guarantee that m_process is not null in these functions?
Comment 3 Anders Carlsson 2016-08-29 12:46:26 PDT
(In reply to comment #2)
> Comment on attachment 287308 [details]
> Patch
> 
> View in context:
> https://bugs.webkit.org/attachment.cgi?id=287308&action=review
> 
> > Source/WebKit2/ChangeLog:8
> > +        The WebPageProxy alreayd knows its WebProcessProxy - no need to look it up from the connection.
> 
> Typo: already misspelled.
> 
> > Source/WebKit2/UIProcess/WebPageProxy.cpp:672
> > +    ASSERT(m_process->connection() == &connection);
> 
> Is there a solid guarantee that m_process is not null in these functions?

m_process is never null. m_process->connection() can be null during launch, but no incoming messages are dispatched at that time.
Comment 4 Anders Carlsson 2016-08-29 12:46:50 PDT
Committed r205137: <http://trac.webkit.org/changeset/205137>