From f0c5b7ea40dcefd1f660aed2c1fd4487511cca16 Mon Sep 17 00:00:00 2001 From: kervala Date: Sat, 10 Dec 2016 13:43:00 +0100 Subject: [PATCH] Changed: Use TCHAR functions --HG-- branch : develop --- code/nel/tools/3d/object_viewer/located_bindable_dialog.cpp | 2 +- code/nel/tools/3d/object_viewer/particle_tree_ctrl.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/code/nel/tools/3d/object_viewer/located_bindable_dialog.cpp b/code/nel/tools/3d/object_viewer/located_bindable_dialog.cpp index 73337e3a5..2242c0684 100644 --- a/code/nel/tools/3d/object_viewer/located_bindable_dialog.cpp +++ b/code/nel/tools/3d/object_viewer/located_bindable_dialog.cpp @@ -764,7 +764,7 @@ void CLocatedBindableDialog::updateZBias() m_ZBias.GetWindowText(value); float zbias = 0.f; int dummy; // to test if end of string as no not wanted extra characters - if (sscanf((LPCTSTR) (value + "\n0"), "%f\n%d", &zbias, &dummy) == 2) + if (_stscanf((LPCTSTR)(value + _T("\n0")), _T("%f\n%d"), &zbias, &dummy) == 2) { NLMISC::safe_cast(_Bindable)->setZBias(-zbias); } diff --git a/code/nel/tools/3d/object_viewer/particle_tree_ctrl.cpp b/code/nel/tools/3d/object_viewer/particle_tree_ctrl.cpp index 332a5163e..bf382f1e4 100644 --- a/code/nel/tools/3d/object_viewer/particle_tree_ctrl.cpp +++ b/code/nel/tools/3d/object_viewer/particle_tree_ctrl.cpp @@ -1147,7 +1147,7 @@ BOOL CParticleTreeCtrl::OnCmdMsg(UINT nID, int nCode, void* pExtra, AFX_CMDHA { float value; int dummy; // to avoid non numeric characters at the end - if (sscanf ((LPCTSTR)(valueDlg.Value + "\n0"), "%f\n%d", &value, &dummy) == 2) + if (_stscanf((LPCTSTR)(valueDlg.Value + _T("\n0")), _T("%f\n%d"), &value, &dummy) == 2) { nlassert(getOwnerNode(nt)->getPSPointer()); getOwnerNode(nt)->getPSPointer()->setZBias(-value);