mirror of
https://github.com/ApfelTeeSaft/reactos.git
synced 2026-08-26 19:33:31 +00:00
[COMCTL32][USER32] Edit: Don't unlock if unlocked on EM_SETHANDLE (#7886)
JIRA issue: CORE-18944 EDIT_EM_GetHandle unlocks the handle, so the next EM_SETHANDLE handler shouldn't unlock the unlocked text. Don't unlock the handle when es->text was NULL on EM_SETHANDLE message handling.
This commit is contained in:
@@ -2715,6 +2715,9 @@ static void EDIT_EM_SetHandle(EDITSTATE *es, HLOCAL hloc)
|
||||
if (!hloc)
|
||||
return;
|
||||
|
||||
#ifdef __REACTOS__
|
||||
if (es->text)
|
||||
#endif
|
||||
EDIT_UnlockBuffer(es, TRUE);
|
||||
|
||||
es->hloc32W = hloc;
|
||||
|
||||
@@ -2898,6 +2898,9 @@ static void EDIT_EM_SetHandle(EDITSTATE *es, HLOCAL hloc)
|
||||
return;
|
||||
}
|
||||
|
||||
#ifdef __REACTOS__
|
||||
if (es->text)
|
||||
#endif
|
||||
EDIT_UnlockBuffer(es, TRUE);
|
||||
|
||||
if(es->is_unicode)
|
||||
|
||||
Reference in New Issue
Block a user