mirror of
https://github.com/reactos/reactos.git
synced 2025-04-26 16:40:27 +00:00
- Add check of returned value for EnumDisplaySettings
svn path=/trunk/; revision=39843
This commit is contained in:
parent
8d143da0d2
commit
bd718d68df
1 changed files with 3 additions and 1 deletions
|
@ -66,7 +66,9 @@ GetSystemColorDepth(VOID)
|
|||
|
||||
pDevMode.dmSize = sizeof(DEVMODE);
|
||||
pDevMode.dmDriverExtra = 0;
|
||||
EnumDisplaySettings(NULL, ENUM_CURRENT_SETTINGS, &pDevMode);
|
||||
|
||||
if (!EnumDisplaySettings(NULL, ENUM_CURRENT_SETTINGS, &pDevMode))
|
||||
return ILC_COLOR;
|
||||
|
||||
switch (pDevMode.dmBitsPerPel)
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue