tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

commit 1f5a942935908ac0a2a6603c6f15dc5858a0795f
parent 4ee598f52d08ca68720cd8a00b4f56b20ccbfa33
Author: Andrew McCreight <continuation@gmail.com>
Date:   Mon,  6 Oct 2025 21:37:28 +0000

Bug 1992524 - Remove warning from nsFrameSelection::RepaintSelection(). r=smaug

This warning is in the top 10 on all 3 desktop platforms and doesn't look very useful.

Differential Revision: https://phabricator.services.mozilla.com/D267683

Diffstat:
Mlayout/generic/nsFrameSelection.cpp | 4+++-
1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/layout/generic/nsFrameSelection.cpp b/layout/generic/nsFrameSelection.cpp @@ -1733,7 +1733,9 @@ nsresult nsFrameSelection::RepaintSelection(SelectionType aSelectionType) { if (!sel) { return NS_ERROR_INVALID_ARG; } - NS_ENSURE_STATE(mPresShell); + if (!mPresShell) { + return NS_ERROR_UNEXPECTED; + } // On macOS, update the selection cache to the new active selection // aka the current selection.