Refactor cli/cppcheckexecutor.cpp

This commit is contained in:
jrp2014 2018-04-05 08:12:15 +02:00 committed by Daniel Marjamäki
parent e65c63e2bb
commit c2e54fa87f
1 changed files with 3 additions and 3 deletions

View File

@ -581,7 +581,7 @@ namespace {
const HANDLE hThread = GetCurrentThread();
BOOL result = pSymInitialize(
hProcess,
0,
nullptr,
TRUE
);
CONTEXT context = *(ex->ContextRecord);
@ -642,7 +642,7 @@ namespace {
}
FreeLibrary(hLibDbgHelp);
hLibDbgHelp=0;
hLibDbgHelp=nullptr;
}
void writeMemoryErrorDetails(FILE* outputFile, PEXCEPTION_POINTERS ex, const char* description)
@ -963,7 +963,7 @@ static inline std::string ansiToOEM(const std::string &msg, bool doConvert)
// ansi code page characters to wide characters
MultiByteToWideChar(CP_ACP, 0, msg.data(), msglength, wcContainer.data(), msglength);
// wide characters to oem codepage characters
WideCharToMultiByte(CP_OEMCP, 0, wcContainer.data(), msglength, const_cast<char *>(result.data()), msglength, NULL, NULL);
WideCharToMultiByte(CP_OEMCP, 0, wcContainer.data(), msglength, const_cast<char *>(result.data()), msglength, nullptr, nullptr);
return result; // hope for return value optimization
}