diff --git a/Windows/Debugger/Debugger_Disasm.cpp b/Windows/Debugger/Debugger_Disasm.cpp index 4a2e54ee9d..112f854ab1 100644 --- a/Windows/Debugger/Debugger_Disasm.cpp +++ b/Windows/Debugger/Debugger_Disasm.cpp @@ -597,10 +597,9 @@ BOOL CDisasm::DlgProc(UINT message, WPARAM wParam, LPARAM lParam) break; case IDC_ALLFUNCTIONS: - { + if (g_symbolMap) g_symbolMap->FillSymbolListBox(GetDlgItem(m_hDlg, IDC_FUNCTIONLIST),ST_FUNCTION); - break; - } + break; default: return FALSE; } @@ -862,7 +861,8 @@ void CDisasm::SetDebugMode(bool _bDebug, bool switchPC) void CDisasm::NotifyMapLoaded() { - g_symbolMap->FillSymbolListBox(GetDlgItem(m_hDlg, IDC_FUNCTIONLIST),ST_FUNCTION); + if (g_symbolMap) + g_symbolMap->FillSymbolListBox(GetDlgItem(m_hDlg, IDC_FUNCTIONLIST),ST_FUNCTION); CtrlDisAsmView *ptr = CtrlDisAsmView::getFrom(GetDlgItem(m_hDlg,IDC_DISASMVIEW)); ptr->clearFunctions(); ptr->redraw(); diff --git a/Windows/Debugger/Debugger_MemoryDlg.cpp b/Windows/Debugger/Debugger_MemoryDlg.cpp index 6943a8b1a3..dd4a3b91ce 100644 --- a/Windows/Debugger/Debugger_MemoryDlg.cpp +++ b/Windows/Debugger/Debugger_MemoryDlg.cpp @@ -95,7 +95,8 @@ void CMemoryDlg::NotifyMapLoaded() if (m_hDlg) { HWND list = GetDlgItem(m_hDlg,IDC_SYMBOLS); - g_symbolMap->FillSymbolListBox(list,ST_DATA); + if (g_symbolMap) + g_symbolMap->FillSymbolListBox(list, ST_DATA); HWND lb = GetDlgItem(m_hDlg,IDC_REGIONS); int sel = ComboBox_GetCurSel(lb); ComboBox_ResetContent(lb);