mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-21 05:09:34 -06:00
Build fix: Android NDK doesn't support any locale switching.
Also, Mac OS X doesn't support DX9.
This commit is contained in:
@ -176,8 +176,10 @@ extern const char *WriteLocation(API_TYPE ApiType);
|
||||
|
||||
const char *GenerateVertexShaderCode(u32 components, API_TYPE ApiType)
|
||||
{
|
||||
#ifndef ANDROID
|
||||
locale_t locale = newlocale(LC_NUMERIC_MASK, "C", NULL); // New locale for compilation
|
||||
locale_t old_locale = uselocale(locale); // Apply the locale for this thread
|
||||
#endif
|
||||
text[sizeof(text) - 1] = 0x7C; // canary
|
||||
|
||||
_assert_(bpmem.genMode.numtexgens == xfregs.numTexGen.numTexGens);
|
||||
@ -644,7 +646,9 @@ const char *GenerateVertexShaderCode(u32 components, API_TYPE ApiType)
|
||||
|
||||
if (text[sizeof(text) - 1] != 0x7C)
|
||||
PanicAlert("VertexShader generator - buffer too small, canary has been eaten!");
|
||||
#ifndef ANDROID
|
||||
uselocale(old_locale); // restore locale
|
||||
freelocale(locale);
|
||||
#endif
|
||||
return text;
|
||||
}
|
||||
|
Reference in New Issue
Block a user