mirror of
https://github.com/reactos/reactos.git
synced 2024-12-28 18:15:11 +00:00
[WIN32SS:NTUSER] Make sure to hold User Global Lock before manipulating desktops. (#4053)
This commit is contained in:
parent
6b7b0f0c7e
commit
5891ab2bfd
1 changed files with 6 additions and 2 deletions
|
@ -561,6 +561,8 @@ IntResolveDesktop(
|
||||||
BOOLEAN bInteractive = FALSE;
|
BOOLEAN bInteractive = FALSE;
|
||||||
BOOLEAN bAccessAllowed = FALSE;
|
BOOLEAN bAccessAllowed = FALSE;
|
||||||
|
|
||||||
|
ASSERT(UserIsEnteredExclusive());
|
||||||
|
|
||||||
ASSERT(phWinSta);
|
ASSERT(phWinSta);
|
||||||
ASSERT(phDesktop);
|
ASSERT(phDesktop);
|
||||||
ASSERT(DesktopPath);
|
ASSERT(DesktopPath);
|
||||||
|
@ -2329,6 +2331,8 @@ IntCreateDesktop(
|
||||||
|
|
||||||
TRACE("Enter IntCreateDesktop\n");
|
TRACE("Enter IntCreateDesktop\n");
|
||||||
|
|
||||||
|
ASSERT(UserIsEnteredExclusive());
|
||||||
|
|
||||||
ASSERT(phDesktop);
|
ASSERT(phDesktop);
|
||||||
*phDesktop = NULL;
|
*phDesktop = NULL;
|
||||||
|
|
||||||
|
@ -2808,7 +2812,7 @@ NtUserResolveDesktop(
|
||||||
if (!NT_SUCCESS(Status))
|
if (!NT_SUCCESS(Status))
|
||||||
return NULL;
|
return NULL;
|
||||||
|
|
||||||
// UserEnterShared();
|
UserEnterExclusive();
|
||||||
|
|
||||||
_SEH2_TRY
|
_SEH2_TRY
|
||||||
{
|
{
|
||||||
|
@ -2863,7 +2867,7 @@ NtUserResolveDesktop(
|
||||||
ReleaseCapturedUnicodeString(&CapturedDesktopPath, UserMode);
|
ReleaseCapturedUnicodeString(&CapturedDesktopPath, UserMode);
|
||||||
|
|
||||||
Quit:
|
Quit:
|
||||||
// UserLeave();
|
UserLeave();
|
||||||
|
|
||||||
/* Dereference the process object */
|
/* Dereference the process object */
|
||||||
ObDereferenceObject(Process);
|
ObDereferenceObject(Process);
|
||||||
|
|
Loading…
Reference in a new issue