diff options
| author | Léo Lam <leo@leolam.fr> | 2022-01-14 00:04:22 +0100 |
|---|---|---|
| committer | Léo Lam <leo@leolam.fr> | 2022-01-14 00:04:22 +0100 |
| commit | 83c5446d852178794450f7c5833f7a047490ff31 (patch) | |
| tree | c154122215e7dd3917ff4d57ed4d35eeb1b46ee1 /Source/Core/VideoBackends/Vulkan/ShaderCompiler.cpp | |
| parent | 07fd17445c6ca4e89b0cef023ba711bb27c920aa (diff) | |
Fix static initialisation order fiasco issue for Version variables
Fixes a crash that could occur if the static constructor function for
the MainSettings.cpp TU happened to run before the variables in
Common/Version.cpp are initialised. (This is known as the static
initialisation order fiasco.)
By using wrapper functions, those variables are now guaranteed to be
constructed on first use.
Diffstat (limited to 'Source/Core/VideoBackends/Vulkan/ShaderCompiler.cpp')
| -rw-r--r-- | Source/Core/VideoBackends/Vulkan/ShaderCompiler.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Source/Core/VideoBackends/Vulkan/ShaderCompiler.cpp b/Source/Core/VideoBackends/Vulkan/ShaderCompiler.cpp index ec38d58009..7da5f827d4 100644 --- a/Source/Core/VideoBackends/Vulkan/ShaderCompiler.cpp +++ b/Source/Core/VideoBackends/Vulkan/ShaderCompiler.cpp @@ -169,7 +169,7 @@ static std::optional<SPIRVCodeVector> CompileShaderToSPV(EShLanguage stage, } stream << "\n"; - stream << "Dolphin Version: " + Common::scm_rev_str + "\n"; + stream << "Dolphin Version: " + Common::GetScmRevStr() + "\n"; stream << "Video Backend: " + g_video_backend->GetDisplayName(); PanicAlertFmt("{} (written to {})", msg, filename); |
