1
0
mirror of https://github.com/mariadb-corporation/mariadb-columnstore-engine.git synced 2025-07-30 19:23:07 +03:00

Remove windows ifdefs

This commit is contained in:
Leonid Fedorov
2023-03-02 15:59:42 +00:00
parent 123c345b40
commit 56f2346083
328 changed files with 9 additions and 19602 deletions

View File

@ -70,11 +70,7 @@ void Log::formatMsg(const std::string& msg, MsgLevel level, std::ostringstream&
if (isDebug(DEBUG_2))
{
oss << " (" << m_pid << ":" <<
#ifdef _MSC_VER
GetCurrentThreadId()
#else
pthread_self()
#endif
<< ") " << MSG_LEVEL_STR[level] << " : " << msg;
}
else
@ -155,19 +151,6 @@ void Log::setLogFileName(const char* logfile, const char* errlogfile, bool conso
m_logFileName = logfile;
m_errlogFileName = errlogfile;
m_bConsoleOutput = consoleFlag;
#ifdef _MSC_VER
// cpimport.bin calls BulkLoad::loadJobInfo() before calling
// BulkLoad::processJob(). loadJobInfo() attempts to write to this log
// before it's opened (by processJob()). This doesn't seem to bother Linux
// but puts Windows in a bad state. Once this logic is fixed, this hack can
// go away.
// This code probably wouldn't hurt if run on Linux, but I'll leave this
// here as a reminder to fix the logic for all platforms.
m_logFile.close();
m_logFile.clear();
m_errLogFile.close();
m_errLogFile.clear();
#endif
m_logFile.open(m_logFileName.c_str(), std::ofstream::out | std::ofstream::app);
m_errLogFile.open(m_errlogFileName.c_str(), std::ofstream::out | std::ofstream::app);
}