fixed: swprintf version for MS Visual

git-svn-id: svn://ttmath.org/publicrep/pikotools/trunk@386 e52654a7-88a9-db11-a3e9-0013d4bc506e
This commit is contained in:
Tomasz Sowa 2012-02-15 07:46:34 +00:00
parent a233f8d4df
commit 8b3c2904aa
1 changed files with 10 additions and 0 deletions

View File

@ -365,7 +365,12 @@ std::wstring & Space::Add(const wchar_t * name, int value)
{
wchar_t value_str[50];
#ifdef _MSC_VER
swprintf(value_str, sizeof(value_str)/sizeof(wchar_t), L"%d", value);
#else
swprintf(value_str, L"%d", value);
#endif
return Add(name, value_str);
}
@ -380,7 +385,12 @@ std::wstring & Space::Add(const wchar_t * name, long value)
{
wchar_t value_str[50];
#ifdef _MSC_VER
swprintf(value_str, sizeof(value_str)/sizeof(wchar_t), L"%ld", value);
#else
swprintf(value_str, L"%ld", value);
#endif
return Add(name, value_str);
}