X-Git-Url: https://git.reactos.org/?p=reactos.git;a=blobdiff_plain;f=win32ss%2Fgdi%2Fgdi32%2Finclude%2Fgdi32p.h;h=03ce3afcf826bffb238ae851de4318698b3aa7f3;hp=f0b4cb46d93b2225e3a5e220e0a5a417db01dcad;hb=b4624f32f37c0855d6694672e2fe9719b312ac36;hpb=b91cf860cd04be4bbfcfa9cb9a479010554362d2;ds=sidebyside diff --git a/win32ss/gdi/gdi32/include/gdi32p.h b/win32ss/gdi/gdi32/include/gdi32p.h index f0b4cb46d93..03ce3afcf82 100644 --- a/win32ss/gdi/gdi32/include/gdi32p.h +++ b/win32ss/gdi/gdi32/include/gdi32p.h @@ -409,6 +409,12 @@ GdiAllocBatchCommand( /* Call win32k, the kernel will call NtGdiFlushUserBatch to flush the current batch */ NtGdiFlush(); + + // If Flushed, lose the hDC for this batch job! See CORE-15839. + if (hdc) + { + if (!pTeb->GdiTebBatch.HDC) pTeb->GdiTebBatch.HDC = hdc; + } } /* Get the head of the entry */