https://git.reactos.org/?p=reactos.git;a=commitdiff;h=b4e781d72dd5f738cc339…
commit b4e781d72dd5f738cc33992c63a067a9bdd9ea18
Author: Hervé Poussineau <hpoussin(a)reactos.org>
AuthorDate: Sun Oct 13 21:35:28 2024 +0200
Commit: Hervé Poussineau <hpoussin(a)reactos.org>
CommitDate: Mon Oct 14 23:26:11 2024 +0200
[WIN32SS:ENG] Make gpPrimaryGraphicsDevice variable static
---
win32ss/gdi/eng/device.c | 2 +-
win32ss/gdi/eng/device.h | 2 --
win32ss/gdi/eng/pdevobj.c | 2 +-
3 files changed, 2 insertions(+), 4 deletions(-)
diff --git a/win32ss/gdi/eng/device.c b/win32ss/gdi/eng/device.c
index 299e75ad4f7..1f11e5fef01 100644
--- a/win32ss/gdi/eng/device.c
+++ b/win32ss/gdi/eng/device.c
@@ -12,7 +12,7 @@
DBG_DEFAULT_CHANNEL(EngDev);
-PGRAPHICS_DEVICE gpPrimaryGraphicsDevice;
+static PGRAPHICS_DEVICE gpPrimaryGraphicsDevice;
static PGRAPHICS_DEVICE gpVgaGraphicsDevice;
static PGRAPHICS_DEVICE gpGraphicsDeviceFirst = NULL;
diff --git a/win32ss/gdi/eng/device.h b/win32ss/gdi/eng/device.h
index 7248598a8f0..54caac283b3 100644
--- a/win32ss/gdi/eng/device.h
+++ b/win32ss/gdi/eng/device.h
@@ -8,8 +8,6 @@ NTAPI
PDEVOBJ_vRefreshModeList(
PPDEVOBJ ppdev);
-extern PGRAPHICS_DEVICE gpPrimaryGraphicsDevice;
-
VOID
APIENTRY
EngFileWrite(
diff --git a/win32ss/gdi/eng/pdevobj.c b/win32ss/gdi/eng/pdevobj.c
index 66d81ea8739..54d69cf7dc7 100644
--- a/win32ss/gdi/eng/pdevobj.c
+++ b/win32ss/gdi/eng/pdevobj.c
@@ -895,7 +895,7 @@ PDEVOBJ_lChangeDisplaySettings(
}
else if (RequestedMode)
{
- pGraphicsDevice = gpPrimaryGraphicsDevice;
+ pGraphicsDevice = EngpFindGraphicsDevice(NULL, 0);
if (!pGraphicsDevice)
{
ERR("Wrong device'\n");