New issue
Advanced search Search tips

Issue 695275 link

Starred by 4 users

Issue metadata

Status: Fixed
Owner:
Closed: May 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 3
Type: Task



Sign in to add a comment

Editor::executeCommand() should have DCEHCK about frame is active

Project Member Reported by yosin@chromium.org, Feb 23 2017

Issue description

Editor::executeCommand() is called by RenderFrameImpl via WebLocalFrameImpl.
RenderFrameImpl may call Editor::executeCommand() during detach[1].

We've not been sure other cases that Edtior::executeCommand() for inactive 
frame. Thus, we should have DCEHCK to check frame is active in Editor::executeCommand().


[1] http://crbug.com/692557 Chrome_Mac: Crash Report - blink::SelectionEditor::updateCachedVisibleSelectionIfNeeded
 
Hi Yosin,

I was going through the code for this issue.

As I can see that in RenderViewImpl::OnExecuteEditCommand
there is a check for webview()->focusedFrame() before calling webview()->focusedFrame()->executeCommand 

but in RenderFrameImpl::OnUndo() it is directly calling frame_->executeCommand without checking for focused frame

So do we need to check for focused frame in Editor::executeCommand() or how can I check for inactive frame ?

If you can please advise me for the same and give me some more directions to proceed.

Thanks
Have added following patch. Please review the code changes.  https://codereview.chromium.org/2910813002/

Comment 3 by yosin@chromium.org, May 31 2017

Owner: yosin@chromium.org
Status: Started (was: Available)
yosin@ is a virtual owner of this issue.
tripta.g@ is working this issue as #c2.
Project Member

Comment 4 by bugdroid1@chromium.org, May 31 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/bdc74113995ad8e4c1b7cb0150431f90d30618bc

commit bdc74113995ad8e4c1b7cb0150431f90d30618bc
Author: tripta.g <tripta.g@samsung.com>
Date: Wed May 31 09:28:42 2017

Editor::executeCommand() should have DCEHCK about frame is active

BUG= 695275 

Review-Url: https://codereview.chromium.org/2910813002
Cr-Commit-Position: refs/heads/master@{#475856}

[modify] https://crrev.com/bdc74113995ad8e4c1b7cb0150431f90d30618bc/third_party/WebKit/Source/core/editing/commands/EditorCommand.cpp

Comment 5 by yosin@chromium.org, May 31 2017

Status: Fixed (was: Started)

Sign in to add a comment