Merge branch 'master' into jgrpp-beta
# Conflicts: # .github/workflows/ci-build.yml # CMakeLists.txt # src/lang/finnish.txt # src/lang/french.txt # src/lang/korean.txt # src/lang/norwegian_bokmal.txt # src/lang/russian.txt # src/lang/spanish.txt # src/misc_gui.cpp # src/newgrf.cpp
This commit is contained in:
@@ -17,6 +17,7 @@
|
||||
#include "win32_s.h"
|
||||
#include <windows.h>
|
||||
#include <mmsystem.h>
|
||||
#include <versionhelpers.h>
|
||||
#include "../os/windows/win32.h"
|
||||
#include "../thread.h"
|
||||
|
||||
@@ -69,7 +70,7 @@ const char *SoundDriver_Win32::Start(const StringList &parm)
|
||||
wfex.nAvgBytesPerSec = wfex.nSamplesPerSec * wfex.nBlockAlign;
|
||||
|
||||
/* Limit buffer size to prevent overflows. */
|
||||
_bufsize = GetDriverParamInt(parm, "bufsize", (GB(GetVersion(), 0, 8) > 5) ? 8192 : 4096);
|
||||
_bufsize = GetDriverParamInt(parm, "bufsize", IsWindowsVistaOrGreater() ? 8192 : 4096);
|
||||
_bufsize = std::min<int>(_bufsize, UINT16_MAX);
|
||||
|
||||
try {
|
||||
|
||||
Reference in New Issue
Block a user