server goes into crash comes to a point of said pieces of code
PHP Code:
void LM::InitLogMesseg()
{
time_t t = g_pSM->GetAdjustedTime();
tm curtime;
localtime_s(&curtime, &t);
-> m_NrmCurDay = curtime.tm_mday; <-
char Path[256];
g_pSM->BuildPath(Path_SM, Path, sizeof(Path), "/logs/UKRCOOP_%04d%02d%02d.log", curtime.tm_year + 1900, curtime.tm_mon + 1, curtime.tm_mday);
m_NrmFileName.assign(Path);
m_DailPrinted = true;
FILE *fp = fopen(m_NrmFileName.c_str(), "a+");
if(m_DailPrinted)
{
char date[32];
m_DailPrinted = false;
strftime(date, sizeof(date), "%m/%d/%Y - %H:%M:%S", &curtime);
fprintf(fp, "L %s: LogMessege log file session started (file \"L%04d%02d%02d.log\") (Version \"%s\")\n", date, curtime.tm_year + 1900, curtime.tm_mon + 1, curtime.tm_mday, SMEXT_CONF_VERSION);
fclose(fp);
}
}
__________________