https://git.reactos.org/?p=reactos.git;a=commitdiff;h=915569a8dee35a1d8af3bf9fab96096b320e2403

commit 915569a8dee35a1d8af3bf9fab96096b320e2403
Author:     Katayama Hirofumi MZ <[email protected]>
AuthorDate: Sun Nov 28 22:23:04 2021 +0900
Commit:     GitHub <[email protected]>
CommitDate: Sun Nov 28 22:23:04 2021 +0900

    [RICHED20] Fail elegantly if pRow or pPara is NULL on ME_EnsureVisible 
(#4126)
    
    CORE-16578
---
 dll/win32/riched20/paint.c | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/dll/win32/riched20/paint.c b/dll/win32/riched20/paint.c
index 72128072380..05be17e24c5 100644
--- a/dll/win32/riched20/paint.c
+++ b/dll/win32/riched20/paint.c
@@ -1279,8 +1279,13 @@ void ME_EnsureVisible(ME_TextEditor *editor, ME_Cursor 
*pCursor)
   ME_DisplayItem *pPara = pCursor->pPara;
   int x, y, yheight;
 
+#ifdef __REACTOS__
+  if (!pRow || !pPara)
+    return;
+#else
   assert(pRow);
   assert(pPara);
+#endif
 
   if (editor->styleFlags & ES_AUTOHSCROLL)
   {

Reply via email to