Issue 962610 in chromium: WebTextCheckingCompletion should be managed with std::unique_ptr

0 views
Skip to first unread message

xiaochengh via monorail

unread,
May 13, 2019, 3:19:54 PM5/13/19
to editi...@chromium.org
Status: Untriaged
Owner: ----
Components: Blink>Editing>Spellcheck
Pri: 3
Type: Task

New issue 962610 by xiaoc...@chromium.org: WebTextCheckingCompletion should be managed with std::unique_ptr
https://bugs.chromium.org/p/chromium/issues/detail?id=962610

Currently, the memory management of WebTextCheckingCompletion is completely manual:
- It's created inside Blink, and passed to components/spellcheck
- components/spellcheck calls WebTextCheckingCompletion::DidFinish/Cancel to delete the object

This management is fragile and can easily cause memory leaks upon code changes, e.g., in unit test IdleSpellCheckControllerTest.ColdModeRangeCrossesShadow

We should use std::unique_ptr() to manage it.

--
You received this message because:
1. A rule CC'd you on the issue
2. You are auto-CC'd on all issues in component Blink>Editing>Spellcheck

You may adjust your notification preferences at:
https://bugs.chromium.org/hosting/settings

Reply to this email to add a comment or make updates.

xiaochengh via monorail

unread,
May 13, 2019, 3:20:06 PM5/13/19
to editi...@chromium.org
Updates:
Owner: xiaoc...@chromium.org
Status: Assigned

Comment #1 on issue 962610 by xiaoc...@chromium.org: WebTextCheckingCompletion should be managed with std::unique_ptr
https://bugs.chromium.org/p/chromium/issues/detail?id=962610#c1

(No comment was entered for this change.)
Reply all
Reply to author
Forward
0 new messages