mirror of
https://github.com/znc/znc.git
synced 2026-07-05 09:21:31 +02:00
Get rid of most strtoul() and atoi() calls and use CString's features instead
git-svn-id: https://znc.svn.sourceforge.net/svnroot/znc/trunk@1320 726aef4b-f618-498e-8847-2d620e286838
This commit is contained in:
+2
-2
@@ -195,7 +195,7 @@ public:
|
||||
return;
|
||||
} else
|
||||
{
|
||||
u_int iNum = atoi(sWhich.c_str());
|
||||
u_int iNum = sWhich.ToUInt();
|
||||
if (iNum >= m_vMessages.size())
|
||||
{
|
||||
PutModNotice("Illegal Message # Requested", "away");
|
||||
@@ -241,7 +241,7 @@ public:
|
||||
m_vMessages.erase(m_vMessages.begin() + a--);
|
||||
continue;
|
||||
}
|
||||
time_t iTime = strtol(sTime.c_str(), NULL, 10);
|
||||
time_t iTime = sTime.ToULong();
|
||||
char szFormat[64];
|
||||
struct tm t;
|
||||
localtime_r(&iTime, &t);
|
||||
|
||||
Reference in New Issue
Block a user