Vector35 / Vector35/binaryninja-api
Crash when creating a new window using right click menu in macOS dock
Open
Nobody has claimed this yet.
Component: UI
Effort: Low
Impact: High
- Dominant language
- C++
- Stars
- 1.3k
- Forks
- 298
- Avg merge
- 5d 5h
- Merged PRs (30d)
- 19
Description
Version and Platform (required):
- Binary Ninja Version: 3.6.4712-dev Personal, 599e2ad7
- OS: macos
- OS Version: 14.1
- CPU Architecture: arm64
Steps To Reproduce:
- Open Binary Ninja
- Use right click on dock icon and click on New Window (It sometimes open a new window sometimes it does not)
- If it opened a new window then skip this step. If not, create a new window with File -> New Window
- Close that new window
- Try to create a new window again from dock icon right click menu
- See the crash
Crash log:
Process: binaryninja [1847]
Path: /Applications/Binary Ninja.app/Contents/MacOS/binaryninja
Identifier: com.vector35.binaryninja
Version: 3.6.4712-dev Personal (3.6.4712-dev Personal)
Code Type: ARM-64 (Native)
System Integrity Protection: enabled
Crashed Thread: 0 Dispatch queue: com.apple.main-thread
Exception Type: EXC_BAD_ACCESS (SIGSEGV)
Exception Codes: KERN_INVALID_ADDRESS at 0x00000ac9d6238828
Exception Codes: 0x0000000000000001, 0x00000ac9d6238828
Termination Reason: Namespace SIGNAL, Code 11 Segmentation fault: 11
Terminating Process: exc handler [1847]
VM Region Info: 0xac9d6238828 is not in any region. Bytes after previous region: 11380961019945 Bytes before following region: 93691118909400
REGION TYPE START - END [ VSIZE] PRT/MAX SHRMOD REGION DETAIL
commpage (reserved) 1000000000-7000000000 [384.0G] ---/--- SM=NUL ...(unallocated)
---> GAP OF 0x5f9000000000 BYTES
MALLOC_NANO 600000000000-600020000000 [512.0M] rw-/rwx SM=PRV
Thread 0 Crashed:: Dispatch queue: com.apple.main-thread
0 libbinaryninjaui.1.dylib 0x1032e78b8 UIActionHandler::isValidAction(QString const&, UIActionContext const&) + 64
1 libbinaryninjaui.1.dylib 0x10332341c 0x1032ac000 + 488476
2 QtCore 0x104b68e60 void doActivate<false>(QObject*, int, void**) + 780
3 QtGui 0x1045b6980 QAction::activate(QAction::ActionEvent) + 368
4 QtCore 0x104b61878 QObject::event(QEvent*) + 612
5 QtWidgets 0x103b94cb8 QApplicationPrivate::notify_helper(QObject*, QEvent*) + 272
6 QtWidgets 0x103b95b08 QApplication::notify(QObject*, QEvent*) + 512
7 QtCore 0x104b1f004 QCoreApplication::notifyInternal2(QObject*, QEvent*) + 292
8 QtCore 0x104b202b4 QCoreApplicationPrivate::sendPostedEvents(QObject*, int, QThreadData*) + 1428
9 libqcocoa.dylib 0x101f30e5c QCocoaEventDispatcherPrivate::processPostedEvents() + 316
10 libqcocoa.dylib 0x101f31840 QCocoaEventDispatcherPrivate::postedEventsSourceCallback(void*) + 460
11 CoreFoundation 0x184f69cfc __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION__ + 28
12 CoreFoundation 0x184f69c90 __CFRunLoopDoSource0 + 176
13 CoreFoundation 0x184f69a60 __CFRunLoopDoSources0 + 340
14 CoreFoundation 0x184f685f0 __CFRunLoopRun + 828
15 CoreFoundation 0x184f67c5c CFRunLoopRunSpecific + 608
16 HIToolbox 0x18f4e4448 RunCurrentEventLoopInMode + 292
17 HIToolbox 0x18f4e4284 ReceiveNextEventCommon + 648
18 HIToolbox 0x18f4e3fdc _BlockUntilNextEventMatchingListInModeWithFilter + 76
19 AppKit 0x188742c54 _DPSNextEvent + 660
20 AppKit 0x188f18ebc -[NSApplication(NSEventRouting) _nextEventMatchingEventMask:untilDate:inMode:dequeue:] + 716
21 AppKit 0x188736100 -[NSApplication run] + 476
22 libqcocoa.dylib 0x101f30084 QCocoaEventDispatcher::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) + 1824
23 QtCore 0x104b28c5c QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) + 532
24 QtCore 0x104b1f690 QCoreApplication::exec() + 112
25 binaryninja 0x1008b99a8 0x100888000 + 203176
26 dyld 0x184b110e0 start + 2360
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the macOS Dock New Window sequence described in the issue and inspect the crash entry point UIActionHandler::isValidAction in libbinaryninjaui. Trace the action after a newly created window is closed, then verify that repeatedly creating a window from the Dock menu no longer crashes.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp, macos
- Domain
- desktop
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100