mirror of
https://github.com/reactos/reactos.git
synced 2025-08-05 06:33:01 +00:00
[WIN32K:NTUSER] Fix NULL pointer dereference in MENU_HideSubPopups
Fixes CORE-19367.
This commit is contained in:
parent
67c28b723e
commit
e8e770fd14
1 changed files with 5 additions and 2 deletions
|
@ -3282,11 +3282,14 @@ static void FASTCALL MENU_HideSubPopups(PWND pWndOwner, PMENU Menu,
|
||||||
{
|
{
|
||||||
PWND pWnd;
|
PWND pWnd;
|
||||||
if (!VerifyMenu(Item->spSubMenu)) return;
|
if (!VerifyMenu(Item->spSubMenu)) return;
|
||||||
pWnd = ValidateHwndNoErr(Item->spSubMenu->hWnd);
|
|
||||||
MENU_HideSubPopups(pWndOwner, Item->spSubMenu, FALSE, wFlags);
|
MENU_HideSubPopups(pWndOwner, Item->spSubMenu, FALSE, wFlags);
|
||||||
MENU_SelectItem(pWndOwner, Item->spSubMenu, NO_SELECTED_ITEM, SendMenuSelect, NULL);
|
MENU_SelectItem(pWndOwner, Item->spSubMenu, NO_SELECTED_ITEM, SendMenuSelect, NULL);
|
||||||
TRACE("M_HSP top p hm %p pWndOwner IDMenu %p\n",top_popup_hmenu,pWndOwner->IDMenu);
|
TRACE("M_HSP top p hm %p pWndOwner IDMenu %p\n",top_popup_hmenu,pWndOwner->IDMenu);
|
||||||
|
pWnd = ValidateHwndNoErr(Item->spSubMenu->hWnd);
|
||||||
|
if (pWnd != NULL)
|
||||||
|
{
|
||||||
co_UserDestroyWindow(pWnd);
|
co_UserDestroyWindow(pWnd);
|
||||||
|
}
|
||||||
|
|
||||||
/* Native returns handle to destroyed window */
|
/* Native returns handle to destroyed window */
|
||||||
if (!(wFlags & TPM_NONOTIFY))
|
if (!(wFlags & TPM_NONOTIFY))
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue