mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-08-04 07:09:03 +00:00
Merge pull request #571 from lioncash/snprintf
VideoCommon: Get rid of an snprintf call in VideoConfig.cpp
This commit is contained in:
commit
80811cb9a1
1 changed files with 3 additions and 3 deletions
|
@ -7,6 +7,7 @@
|
||||||
#include "Common/Common.h"
|
#include "Common/Common.h"
|
||||||
#include "Common/FileUtil.h"
|
#include "Common/FileUtil.h"
|
||||||
#include "Common/IniFile.h"
|
#include "Common/IniFile.h"
|
||||||
|
#include "Common/StringUtil.h"
|
||||||
#include "Core/ConfigManager.h"
|
#include "Core/ConfigManager.h"
|
||||||
#include "Core/Core.h"
|
#include "Core/Core.h"
|
||||||
#include "Core/Movie.h"
|
#include "Core/Movie.h"
|
||||||
|
@ -125,9 +126,8 @@ void VideoConfig::GameIniLoad()
|
||||||
#define CHECK_SETTING(section, key, var) do { \
|
#define CHECK_SETTING(section, key, var) do { \
|
||||||
decltype(var) temp = var; \
|
decltype(var) temp = var; \
|
||||||
if (iniFile.GetIfExists(section, key, &var) && var != temp) { \
|
if (iniFile.GetIfExists(section, key, &var) && var != temp) { \
|
||||||
char buf[256]; \
|
std::string msg = StringFromFormat("Note: Option \"%s\" is overridden by game ini.", key); \
|
||||||
snprintf(buf, sizeof(buf), "Note: Option \"%s\" is overridden by game ini.", key); \
|
OSD::AddMessage(msg, 7500); \
|
||||||
OSD::AddMessage(buf, 7500); \
|
|
||||||
gfx_override_exists = true; \
|
gfx_override_exists = true; \
|
||||||
} \
|
} \
|
||||||
} while (0)
|
} while (0)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue