Fixed compiler warnings about adding integer to char.

This commit is contained in:
Kelvin Lee 2016-09-10 10:18:34 +10:00 committed by tomcw
parent 03996c45a8
commit 20a1a9a884

View File

@ -2053,7 +2053,7 @@ bool MB_LoadSnapshot(YamlLoadHelper& yamlLoadHelper, UINT slot, UINT version)
for(UINT i=0; i<NUM_MB_UNITS; i++)
{
char szNum[2] = {'0'+i,0};
char szNum[2] = {'0'+char(i),0};
std::string unit = std::string(SS_YAML_KEY_MB_UNIT) + std::string(szNum);
if (!yamlLoadHelper.GetSubMap(unit))
throw std::string("Card: Expected key: ") + std::string(unit);
@ -2157,7 +2157,7 @@ bool Phasor_LoadSnapshot(YamlLoadHelper& yamlLoadHelper, UINT slot, UINT version
for(UINT i=0; i<NUM_PHASOR_UNITS; i++)
{
char szNum[2] = {'0'+i,0};
char szNum[2] = {'0'+char(i),0};
std::string unit = std::string(SS_YAML_KEY_MB_UNIT) + std::string(szNum);
if (!yamlLoadHelper.GetSubMap(unit))
throw std::string("Card: Expected key: ") + std::string(unit);