[openrtm-commit:02270] r2875 - branches/DEV_IQ_2016/OpenRTM-aist/src/lib/rtm
openrtm @ openrtm.org
openrtm @ openrtm.org
2017年 1月 19日 (木) 15:39:45 JST
Author: sec_fukai
Date: 2017-01-19 15:39:45 +0900 (Thu, 19 Jan 2017)
New Revision: 2875
Modified:
branches/DEV_IQ_2016/OpenRTM-aist/src/lib/rtm/SystemLogger.cpp
Log:
[compat,->DEV_IQ_2016]Modify coding style. refs #3816
Modified: branches/DEV_IQ_2016/OpenRTM-aist/src/lib/rtm/SystemLogger.cpp
===================================================================
--- branches/DEV_IQ_2016/OpenRTM-aist/src/lib/rtm/SystemLogger.cpp 2017-01-19 06:28:05 UTC (rev 2874)
+++ branches/DEV_IQ_2016/OpenRTM-aist/src/lib/rtm/SystemLogger.cpp 2017-01-19 06:39:45 UTC (rev 2875)
@@ -23,6 +23,8 @@
#define snprintf _snprintf
#endif
+#define MAXSIZE 256
+
namespace RTC
{
const char* Logger::m_levelString[] =
@@ -150,8 +152,7 @@
*/
std::string Logger::getDate(void)
{
- const int maxsize = 256;
- char buf[maxsize];
+ char buf[MAXSIZE];
coil::TimeValue tm(m_clock->gettime());
time_t timer;
@@ -167,9 +168,11 @@
{
char msec[4];
#ifdef WIN32
- _snprintf(msec, sizeof(msec), "%03d", static_cast<int>(tm.usec() / 1000));
+ _snprintf(msec, sizeof(msec), "%03d",
+ static_cast<int>(tm.usec() / 1000));
#else
- snprintf(msec, sizeof(msec), "%03d", static_cast<int>(tm.usec() / 1000));
+ snprintf(msec, sizeof(msec), "%03d",
+ static_cast<int>(tm.usec() / 1000));
#endif
coil::replaceString(fmt, "#m#", msec);
}
More information about the openrtm-commit
mailing list