Viewing Issue Advanced Details
ID Category [?] Severity [?] Reproducibility Date Submitted Last Update
09377 Debugger Critical (emulator) Always 2 days ago 2 days ago
Tester jman View Status Public Platform MAME (Official Binary)
Assigned To cuavas Resolution Fixed OS Windows (x64)
Status [?] Resolved Driver
Version 0.285 Fixed in Version 0.286GIT Build x64
Fixed in Git Commit 9d034a0 Github Pull Request #
Summary Regresssion 09377: Memory viewer in debugger: Right click causes MAME crash
Description Right click causes MAME crash in memory window except CPU address space insted of copy / paste menu.
Steps To Reproduce 1) Execute MAME with "puckman -debug".
2) Open memory viewer window by Ctlr+M (or Debug -> New Memory Window).
3) Select "Region ':maincpu'".
4) Move cursor to a value in memory viewer.
5) Click right button on mouse.
Additional Information
Github Commit
Flags Regression
Regression Version 0.285
Affected Sets / Systems Memory viewer in debugger
Attached Files
 
Relationships
There are no relationship linked to this issue.
Notes
3
User avatar
No.24096
Osso
Moderator
2 days ago
Thread 1 received signal SIGSEGV, Segmentation fault.
0x00007ff66dce08ea in osd::debugger::win::memoryview_info::update_context_menu(HMENU__*) ()
(gdb) bt 30
#0 0x00007ff66dce08ea in osd::debugger::win::memoryview_info::update_context_menu(HMENU__*) ()
#1 0x00007ff66dcdd5a2 in osd::debugger::win::debugview_info::process_context_menu(int, int) ()
#2 0x00007ff66dcdd7bf in osd::debugger::win::debugview_info::view_proc(unsigned int, unsigned long long, long long) ()
#3 0x00007ff94fc47846 in USER32!CallWindowProcW () from C:\WINDOWS\System32\user32.dll
#4 0x00007ff94fc46b53 in USER32!SendMessageW () from C:\WINDOWS\System32\user32.dll
#5 0x00007ff94fc4447c in USER32!GetSystemMetrics () from C:\WINDOWS\System32\user32.dll
#6 0x00007ff94fc4511e in USER32!IsWindowUnicode () from C:\WINDOWS\System32\user32.dll
#7 0x00007ff94fc47846 in USER32!CallWindowProcW () from C:\WINDOWS\System32\user32.dll
#8 0x00007ff94fc4539d in USER32!IsWindowUnicode () from C:\WINDOWS\System32\user32.dll
#9 0x00007ff66c969487 in osd::(anonymous namespace)::debugger_windows::wait_for_debugger(device_t&, bool) ()
#10 0x00007ff668f22ffb in debugger_cpu::wait_for_debugger(device_t&) ()
#11 0x00007ff668f269f6 in device_debug::instruction_hook(unsigned int) ()
#12 0x00007ff666763a5c in mcs51_cpu_device::execute_run() ()
#13 0x00007ff6662c7568 in device_scheduler::timeslice() ()
#14 0x00007ff6662d3be8 in running_machine::run(bool) ()
#15 0x00007ff669003cc6 in mame_machine_manager::execute() ()
#16 0x00007ff66c941b01 in cli_frontend::start_execution(mame_machine_manager*, std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > const&) ()
#17 0x00007ff66c942eb6 in cli_frontend::execute(std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > >&) ()
#18 0x00007ff669004df7 in emulator_info::start_frontend(emu_options&, osd_interface&, std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::allocator<std::_--Type <RET> for more, q to quit, c to continue without paging--
_cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > >&) ()
#19 0x00007ff6660c5d78 in main ()
User avatar
No.24097
cuavas
Administrator
2 days ago
It causes an assertion failure in debug builds.

Assertion failed: index >= 0 && index < int(m_addrspace.size()) && m_addrspace[index], file ../../../../../src/emu/dimemory.h, line 66
[Switching to Thread 2816.0x6264]

Thread 1 hit Breakpoint 1, 0x00007ffd773bf1e7 in msvcrt!abort () from C:\WINDOWS\System32\msvcrt.dll
(gdb) where
#0 0x00007ffd773bf1e7 in msvcrt!abort () from C:\WINDOWS\System32\msvcrt.dll
#1 0x00007ffd773bda39 in msvcrt!_wassert () from C:\WINDOWS\System32\msvcrt.dll
#2 0x00007ff7f6d1eef2 in osd::debugger::win::memoryview_info::update_context_menu(HMENU__*) ()
#3 0x00007ff7f6d1bae0 in osd::debugger::win::debugview_info::process_context_menu(int, int) ()
#4 0x00007ff7f6d1bbc0 in osd::debugger::win::debugview_info::view_proc(unsigned int, unsigned long long, long long)
    ()
#5 0x00007ffd7757e858 in USER32!CallWindowProcW () from C:\WINDOWS\System32\user32.dll
#6 0x00007ffd7757de1b in USER32!SendMessageW () from C:\WINDOWS\System32\user32.dll
#7 0x00007ffd775ad7c4 in USER32!SetWindowsHookExAW () from C:\WINDOWS\System32\user32.dll
#8 0x00007ffd7757c7b8 in USER32!GetWindowTextW () from C:\WINDOWS\System32\user32.dll
#9 0x00007ffd7757e858 in USER32!CallWindowProcW () from C:\WINDOWS\System32\user32.dll
#10 0x00007ffd7757e299 in USER32!DispatchMessageW () from C:\WINDOWS\System32\user32.dll
#11 0x00007ff7f5e912ec in osd::(anonymous namespace)::debugger_windows::wait_for_debugger(device_t&, bool) ()
#12 0x00007ff7f400e900 in debugger_cpu::wait_for_debugger(device_t&) ()
#13 0x00007ff7f400ec4d in device_debug::instruction_hook(unsigned int) ()
#14 0x00007ff7f39ed2cc in m68000_device::execute_run() ()
#15 0x00007ff7f389a011 in device_scheduler::timeslice() ()
#16 0x00007ff7f38f8bd6 in running_machine::run(bool) ()
#17 0x00007ff7f3fc3edb in mame_machine_manager::execute() ()
#18 0x00007ff7f5dbe3a9 in cli_frontend::start_execution(mame_machine_manager*, std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > const&) ()
#19 0x00007ff7f5dbe95d in cli_frontend::execute(std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > >&) ()
#20 0x00007ff7f3fc0079 in emulator_info::start_frontend(emu_options&, osd_interface&, std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > >&) ()
#21 0x00007ff7f6fb27ac in main ()

The issue is that it’s unsafe to call device_memory_interface::space with an invalid space index.
User avatar
No.24098
cuavas
Administrator
2 days ago
And there are likely more instances of this in the other debugger implementations...