15th Anniversary
3 years ago
This blog is about debugging applications on Windows platform. Almost every day I have deal with tasks related to debugging. Some of them are challenge, some - cognitive, some - just funny. In this blog I will write about most challenge, cognitive or funny of them. I hope you enjoy!
LRESULT CToolTipCtrl::OnAddTool(WPARAM wParam, LPARAM lParam) { TOOLINFO ti = *(LPTOOLINFO)lParam; <----- HERE if ((ti.hinst == NULL) && (ti.lpszText != LPSTR_TEXTCALLBACK) && (ti.lpszText != NULL)) { void* pv; if (!m_mapString.Lookup(ti.lpszText, pv)) m_mapString.SetAt(ti.lpszText, NULL); // set lpszText to point to the permanent memory associated // with the CString VERIFY(m_mapString.LookupKey(ti.lpszText, ti.lpszText)); } return DefWindowProc(TTM_ADDTOOL, wParam, (LPARAM)&ti); } |