[CONSRV] Initialize rcFramebuffer in every case, otherwise it is left unintialized in case of e.g. console termination. (#428, #429)

Fixes CORE-14463. Debugged and and fix suggested by Timo Kreuzer.

Signed-off-by: Michael Fritscher <reactos@mifritscher.de>
This commit is contained in:
Michael Fritscher 2018-03-11 17:49:17 +01:00 committed by Hermès Bélusca-Maïto
parent 4ddb1bfd96
commit 602db40277
No known key found for this signature in database
GPG key ID: 3B2539C65E7B93D0
2 changed files with 4 additions and 0 deletions

View file

@ -129,6 +129,8 @@ GuiPaintGraphicsBuffer(PGRAPHICS_SCREEN_BUFFER Buffer,
PCONSRV_CONSOLE Console = Buffer->Header.Console;
// ASSERT(Console == GuiData->Console);
SetRectEmpty(&rcFramebuffer);
if (Buffer->BitMap == NULL) return;
if (!ConDrvValidateConsoleUnsafe((PCONSOLE)Console, CONSOLE_RUNNING, TRUE)) return;

View file

@ -358,6 +358,8 @@ GuiPaintTextModeBuffer(PTEXTMODE_SCREEN_BUFFER Buffer,
HFONT OldFont, NewFont;
BOOLEAN IsUnderline;
SetRectEmpty(&rcFramebuffer);
if (Buffer->Buffer == NULL) return;
if (!ConDrvValidateConsoleUnsafe((PCONSOLE)Console, CONSOLE_RUNNING, TRUE)) return;