Closed Bug 1703521 Opened 3 years ago Closed 3 years ago

Crash in [@ nsXULPopupManager::RollupNativeMenu]

Categories

(Core :: Widget: Cocoa, defect)

Firefox 89
Unspecified
macOS
defect

Tracking

()

RESOLVED FIXED
89 Branch
Tracking Status
firefox-esr78 --- unaffected
firefox87 --- unaffected
firefox88 --- unaffected
firefox89 --- fixed

People

(Reporter: emilghitta, Assigned: mstange)

References

Details

(Keywords: crash, Whiteboard: [Fixed by 1703333] )

Crash Data

Crash report: https://crash-stats.mozilla.org/report/index/f2566fcb-83f9-4db2-a45e-348b30210407

MOZ_CRASH Reason: MOZ_RELEASE_ASSERT(!mNativeMenu) (OnNativeMenuClosed should have been called)

Top 10 frames of crashing thread:

0 XUL nsXULPopupManager::RollupNativeMenu layout/xul/nsXULPopupManager.cpp:200
1 XUL -[ChildView maybeRollup:] widget/cocoa/nsChildView.mm:2594
2 XUL -[ChildView smartMagnifyWithEvent:] widget/cocoa/nsChildView.mm:2776
3 AppKit -[NSWindow _reallySendEvent:isDelayedEvent:] 
4 AppKit -[NSWindow sendEvent:] 
5 XUL -[ToolbarWindow sendEvent:] widget/cocoa/nsCocoaWindow.mm:3838
6 AppKit routeGestureEvent 
7 AppKit -[NSApplication sendEvent:] 
8 XUL -[GeckoNSApplication sendEvent:] widget/cocoa/nsAppShell.mm:160
9 XUL nsAppShell::ProcessNextNativeEvent widget/cocoa/nsAppShell.mm:639

Just encountered this crash on macOS 10.15 randomly while interacting with the native macOS context menu & with the double-tap to zoom functionality. I'm not sure what steps triggered this crash but I'm actively looking into it.

Feel free to change the component if needed.

Severity: -- → S2

Update:

Preconditions

  • Have widget.macos.native-context-menus & browser.proton.enabled prefs enabled
  • Ensure that apz.mac.enabled_double_tap_zoom_touchpad_gesture pref is enabled (it should be enabled by default in Nightly builds)
  • Ensure that the "Smart Zoom" functionality is enabled inside the System Preferences > Trackpad> Scroll & Zoom section.

I have reproduced this crash again a couple of times:

Unfortunately, as mentioned in the bug's description this issue occurs quite randomly and after stress testing the context menu & duble-tap to zoom functionality.

I managed to capture the crash occurrence inside a screencast (Mozilla account needed)

Some notes about the screencast:

  • If the user double taps on the trackpad twice (with 2 fingers) in order to trigger the double-tap to zoom functionality while the macOS native context menu is open, the double-tap to zoom action awaits for the context menu to be dismissed (by the user) before moving the zoom focus to the desired area on the page. This seems to be expected as Safari behaves the same.
  • Something that cannot be seen on the screencast is that while the maOS native context menu is open I'm double-tapping with 2 fingers on the trackpad quite frequently (almost as in spamming this input). The crash occurred while I was spamming the double-tap to zoom functionality while the macOS native context menu was displayed.

This issue occurs quite randomly (managed to trigger 2 different crashes in ~2 hrs of testing this).

Since this involves 2 features I prefer not to block one or the other's meta before waiting for engineering's input on this one. I'm going to allocate some time in stress testing this while having widget.macos.native-context.menus pref set to false

This should be fixed in today's Nightly. I removed the crashing assertion in bug 1703333.

Thanks Markus!

Marking this as fixed by Bug 1703333

Status: NEW → RESOLVED
Closed: 3 years ago
Resolution: --- → FIXED
Whiteboard: [Fixed by 1703333]
Assignee: nobody → mstange.moz
Depends on: 1703333
Target Milestone: --- → 89 Branch
You need to log in before you can comment on or make changes to this bug.