diff --git a/base/applications/regedit/childwnd.c b/base/applications/regedit/childwnd.c index 96b313e7416..19c4cea780f 100644 --- a/base/applications/regedit/childwnd.c +++ b/base/applications/regedit/childwnd.c @@ -384,7 +384,7 @@ LRESULT CALLBACK ChildWndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lPa DestroyTreeView(g_pChildWnd->hTreeWnd); DestroyMainMenu(); DestroyIcon(g_pChildWnd->hArrowIcon); - free(g_pChildWnd); + HeapFree(GetProcessHeap(), 0, g_pChildWnd); g_pChildWnd = NULL; PostQuitMessage(0); break;