Closed Bug 1987777 Opened 4 months ago Closed 4 months ago

Firefox app crashes when pressing back button [@ mozilla::WeakPtr<T>::operator bool ]

Categories

(Core :: DOM: Navigation, defect, P2)

Firefox 144
defect
Points:
2

Tracking

()

VERIFIED FIXED
144 Branch
Tracking Status
firefox-esr115 --- unaffected
firefox-esr128 --- unaffected
firefox-esr140 --- unaffected
firefox142 --- unaffected
firefox143 --- unaffected
firefox144 + verified

People

(Reporter: jib, Assigned: Sasha)

References

(Regression)

Details

(Keywords: regression, Whiteboard: [webdriver:m17])

Crash Data

Attachments

(1 file)

STR:

  1. Open https://blog.mozilla.org/webrtc/unbundling-mediastreamtrackprocessor-and-videotrackgenerator/
  2. Click the first link (labeled "worker-only") in the second paragraph
  3. Click the back button

Expected result:

  • Blog reappears

Actual result:

0 	XUL 	RefPtr<mozilla::detail::WeakReference>::get() const 	mfbt/RefPtr.h:314 	inlined
0 	XUL 	RefPtr<mozilla::detail::WeakReference>::operator->() const 	mfbt/RefPtr.h:344 	inlined
0 	XUL 	mozilla::WeakPtr<mozilla::dom::WindowGlobalChild, (mozilla::detail::WeakPtrDestructorBehavior)0>::operator bool() const 	mfbt/WeakPtr.h:302 	inlined
0 	XUL 	mozilla::dom::WindowContext::GetInnerWindow() const 	docshell/base/WindowContext.cpp:96 	inlined
0 	XUL 	mozilla::dom::BrowsingContext::DidSet(std::__1::integral_constant<unsigned long, (unsigned long)59>, nsTString<char>&&)::$_0::operator()(mozilla::dom::BrowsingContext*) const 	docshell/base/BrowsingContext.cpp:3153 	inlined
0 	XUL 	std::__1::__invoke[abi:nn190102]<mozilla::dom::BrowsingContext::DidSet(std::__1::integral_constant<unsigned long, (unsigned long)59>, nsTString<char>&&)::$_0&, mozilla::dom*>(mozilla::dom*&&, mozilla::dom::BrowsingContext::DidSet(std::__1::integral_constant<unsigned long, (unsigned long)59>, nsTString<char>&&)::$_0&) 	/builds/worker/fetches/MacOSX15.5.sdk/usr/include/c++/v1/__type_traits/invoke.h:149 	inlined
0 	XUL 	std::__1::__invoke_void_return_wrapper<void, true>::__call[abi:nn190102]<mozilla::dom::BrowsingContext::DidSet(std::__1::integral_constant<unsigned long, (unsigned long)59>, nsTString<char>&&)::$_0&, mozilla::dom*>(mozilla::dom::BrowsingContext::DidSet(std::__1::integral_constant<unsigned long, (unsigned long)59>, nsTString<char>&&)::$_0&, mozilla::dom*) 	/builds/worker/fetches/MacOSX15.5.sdk/usr/include/c++/v1/__type_traits/invoke.h:224 	inlined
0 	XUL 	std::__1::__function::__alloc_func<mozilla::dom::BrowsingContext::DidSet(std::__1::integral_constant<unsigned long, (unsigned long)59>, nsTString<char>&&)::$_0, std::__1::allocator<mozilla::dom::BrowsingContext::DidSet(std::__1::integral_constant<unsigned long, (unsigned long)59>, nsTString<char>&&)::$_0>, void (mozilla::dom::BrowsingContext*)>::operator()[abi:nn190102](mozilla::dom::BrowsingContext*&&) 	/builds/worker/fetches/MacOSX15.5.sdk/usr/include/c++/v1/__functional/function.h:171 	inlined
0 	XUL 	std::__1::__function::__func<mozilla::dom::BrowsingContext::DidSet(std::__1::integral_constant<unsigned long, (unsigned long)59>, nsTString<char>&&)::$_0, std::__1::allocator<mozilla::dom::BrowsingContext::DidSet(std::__1::integral_constant<unsigned long, (unsigned long)59>, nsTString<char>&&)::$_0>, void (mozilla::dom::BrowsingContext*)>::operator()(mozilla::dom::BrowsingContext*&&) 	/builds/worker/fetches/MacOSX15.5.sdk/usr/include/c++/v1/__functional/function.h:313 	context
1 	XUL 	std::__1::__function::__value_func<void (mozilla::dom::BrowsingContext*)>::operator()[abi:nn190102](mozilla::dom::BrowsingContext*&&) const 	/builds/worker/fetches/MacOSX15.5.sdk/usr/include/c++/v1/__functional/function.h:430 	inlined
1 	XUL 	std::__1::function<void (mozilla::dom::BrowsingContext*)>::operator()(mozilla::dom::BrowsingContext*) const 	/builds/worker/fetches/MacOSX15.5.sdk/usr/include/c++/v1/__functional/function.h:989 	inlined
1 	XUL 	mozilla::dom::BrowsingContext::PreOrderWalkVoid(std::__1::function<void (mozilla::dom::BrowsingContext*)> const&) 	docshell/base/BrowsingContext.cpp:1296 	cfi
2 	XUL 	mozilla::dom::BrowsingContext::PreOrderWalkVoid(std::__1::function<void (mozilla::dom::BrowsingContext*)> const&) 	docshell/base/BrowsingContext.cpp:1302 	cfi
3 	XUL 	mozilla::dom::BrowsingContext::PreOrderWalkVoid(std::__1::function<void (mozilla::dom::BrowsingContext*)> const&) 	docshell/base/BrowsingContext.cpp:1302 	cfi
4 	XUL 	mozilla::dom::BrowsingContext::PreOrderWalk<mozilla::dom::BrowsingContext::DidSet(std::__1::integral_constant<unsigned long, (unsigned long)59>, nsTString<char>&&)::$_0>(mozilla::dom::BrowsingContext::DidSet(std::__1::integral_constant<unsigned long, (unsigned long)59>, nsTString<char>&&)::$_0&&) 	docshell/base/BrowsingContext.h:592 	inlined
4 	XUL 	mozilla::dom::BrowsingContext::DidSet(std::__1::integral_constant<unsigned long, (unsigned long)59>, nsTString<char>&&) 	docshell/base/BrowsingContext.cpp:3149 	cfi
5 	XUL 	mozilla::dom::syncedcontext::Transaction<mozilla::dom::BrowsingContext>::Apply(mozilla::dom::BrowsingContext*, bool)::{lambda(auto:1)#1}::operator()<std::__1::integral_constant<unsigned long, (unsigned long)59> >(std::__1::integral_constant<unsigned long, (unsigned long)59>) const 	docshell/base/SyncedContextInlines.h:224

Regression range:

Set release status flags based on info from the regressing bug 1980211

:Sasha, since you are the author of the regressor, bug 1980211, could you take a look? Also, could you set the severity field?

For more information, please visit BugBot documentation.

Crash Signature: [@ mozilla::WeakPtr<T>::operator bool]

I can see the crash as well. The problematic patch from bug 1980211 seems to be because it's also happening without Remote Agent being active:
https://hg-edge.mozilla.org/integration/autoland/rev/33dcf5c2e643b94e90a0a197c99112a080501a12

Component: WebDriver BiDi → DOM: Navigation
Product: Remote Protocol → Core
Version: unspecified → Firefox 144
Assignee: nobody → aborovova
Status: NEW → ASSIGNED
Flags: needinfo?(aborovova)
Attachment #9512512 - Attachment description: Bug 1987777 - Reapply language and timezone overrides only when they exist to avoid the crash. → Bug 1987777 - Reapply language and timezone overrides only when they exist and add the checks for WindowContext to avoid the crash.
Points: --- → 2
Priority: -- → P2
Whiteboard: [webdriver:m17]
Pushed by aborovova@mozilla.com: https://github.com/mozilla-firefox/firefox/commit/79dc26709901 https://hg.mozilla.org/integration/autoland/rev/3b7697e19437 Reapply language and timezone overrides only when they exist and add the checks for WindowContext to avoid the crash. r=dom-core,smaug
Status: ASSIGNED → RESOLVED
Closed: 4 months ago
Resolution: --- → FIXED
Target Milestone: --- → 144 Branch

Verified fixed with Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:144.0) Gecko/20100101 Firefox/144.0 ID:20250913092312. Thanks Sasha!

Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: