Make bugfix consistent with official code
This commit is contained in:
parent
409453a6a1
commit
2a0570df94
1 changed files with 9 additions and 0 deletions
|
@ -279,13 +279,19 @@ int WINAPI WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPSTR lpCmdLine
|
||||||
if (conf.display_mode == 1)
|
if (conf.display_mode == 1)
|
||||||
{
|
{
|
||||||
if (!StartDirectDraw(hWnd, 0, 0))
|
if (!StartDirectDraw(hWnd, 0, 0))
|
||||||
|
{
|
||||||
|
ReleaseMutex(hMutex);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if (!StartDirectDraw(hWnd, 1, 0))
|
if (!StartDirectDraw(hWnd, 1, 0))
|
||||||
|
{
|
||||||
|
ReleaseMutex(hMutex);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
#else
|
#else
|
||||||
// Doesn't handle StartDirectDraw failing
|
// Doesn't handle StartDirectDraw failing
|
||||||
if (conf.display_mode == 1)
|
if (conf.display_mode == 1)
|
||||||
|
@ -338,7 +344,10 @@ int WINAPI WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPSTR lpCmdLine
|
||||||
|
|
||||||
#ifdef FIX_BUGS
|
#ifdef FIX_BUGS
|
||||||
if (!StartDirectDraw(hWnd, 2, depth))
|
if (!StartDirectDraw(hWnd, 2, depth))
|
||||||
|
{
|
||||||
|
ReleaseMutex(hMutex);
|
||||||
return 0;
|
return 0;
|
||||||
|
}
|
||||||
#else
|
#else
|
||||||
// Doesn't handle StartDirectDraw failing
|
// Doesn't handle StartDirectDraw failing
|
||||||
StartDirectDraw(hWnd, 2, depth);
|
StartDirectDraw(hWnd, 2, depth);
|
||||||
|
|
Loading…
Add table
Reference in a new issue