if (!::DeleteFile(m_tempFilenameDst.c_str()))
{
LogErrorString(Fmt(_T("DeleteFile(%s) failed: %s")
- , m_tempFilenameDst.c_str(), GetSysError(GetLastError())));
+ , m_tempFilenameDst.c_str(), GetSysError(GetLastError()).c_str()));
}
// we may reuse the temp filename
// tempFilenameDst.Empty();
if (!::DeleteFile(m_filename.c_str()))
{
LogErrorString(Fmt(_T("DeleteFile(%s) failed: %s")
- , m_filename.c_str(), GetSysError(GetLastError())));
+ , m_filename.c_str(), GetSysError(GetLastError()).c_str()));
}
::MoveFile(m_tempFilenameDst.c_str(), m_filename.c_str());
}
FileWriteString(_T("\r\n Font:\r\n"));
FileWriteString(Fmt(_T(" Font facename: %s\r\n"), m_fontSettings.sFacename.c_str()));
FileWriteString(Fmt(_T(" Font charset: %d (%s)\r\n"), m_fontSettings.nCharset,
- FontCharsetName(m_fontSettings.nCharset)));
+ FontCharsetName(m_fontSettings.nCharset).c_str()));
// System settings
FileWriteString(_T("\r\nSystem settings:\r\n"));
if (!::DeleteFile(pszFileName))
{
LogErrorString(Fmt(_T("DeleteFile(%s) failed: %s"),
- pszFileName, GetSysError(GetLastError())));
+ pszFileName, GetSysError(GetLastError()).c_str()));
}
return nRetVal;
sError = uniErr.GetError().c_str();
if (bTempFile)
LogErrorString(Fmt(_T("Opening file %s failed: %s"),
- pszFileName, sError));
+ pszFileName, sError.c_str()));
else
LogErrorString(Fmt(_T("Opening file %s failed: %s"),
- sIntermediateFilename, sError));
+ sIntermediateFilename.c_str(), sError.c_str()));
}
return SAVE_FAILED;
}
if (!::DeleteFile(sIntermediateFilename.c_str()))
{
LogErrorString(Fmt(_T("DeleteFile(%s) failed: %s"),
- sIntermediateFilename.c_str(), GetSysError(GetLastError())));
+ sIntermediateFilename.c_str(), GetSysError(GetLastError()).c_str()));
}
// returns now, don't overwrite the original file
return SAVE_PACK_FAILED;
if (!::DeleteFile(sIntermediateFilename.c_str()))
{
LogErrorString(Fmt(_T("DeleteFile(%s) failed: %s"),
- sIntermediateFilename.c_str(), GetSysError(GetLastError())));
+ sIntermediateFilename.c_str(), GetSysError(GetLastError()).c_str()));
}
sIntermediateFilename = csTempFileName;
}
if (!::DeleteFile(sIntermediateFilename.c_str()))
{
LogErrorString(Fmt(_T("DeleteFile(%s) failed: %s"),
- sIntermediateFilename.c_str(), GetSysError(GetLastError())));
+ sIntermediateFilename.c_str(), GetSysError(GetLastError()).c_str()));
}
if (bClearModifiedFlag)
{
{
sError = GetSysError(GetLastError());
LogErrorString(Fmt(_T("CopyFile(%s, %s) failed: %s"),
- sIntermediateFilename.c_str(), pszFileName, sError));
+ sIntermediateFilename.c_str(), pszFileName, sError.c_str()));
}
}
else
if (!::DeleteFile(strFile1Temp.c_str()))
{
LogErrorString(Fmt(_T("DeleteFile(%s) failed: %s"),
- strFile1Temp.c_str(), GetSysError(GetLastError())));
+ strFile1Temp.c_str(), GetSysError(GetLastError()).c_str()));
}
strFile1Temp.erase();
}
if (!::DeleteFile(strFile2Temp.c_str()))
{
LogErrorString(Fmt(_T("DeleteFile(%s) failed: %s"),
- strFile2Temp.c_str(), GetSysError(GetLastError())));
+ strFile2Temp.c_str(), GetSysError(GetLastError()).c_str()));
}
strFile2Temp.erase();
}
{
WriteString(_T("")); // @todo xml declaration
WriteString(_T("<WinMergeDiffReport version=\"1\">\n"));
- WriteString(Fmt(_T("<left>%s</left>\n"), m_rootPaths.GetLeft()));
- WriteString(Fmt(_T("<right>%s</right>\n"), m_rootPaths.GetRight()));
+ WriteString(Fmt(_T("<left>%s</left>\n"), m_rootPaths.GetLeft().c_str()));
+ WriteString(Fmt(_T("<right>%s</right>\n"), m_rootPaths.GetRight().c_str()));
WriteString(Fmt(_T("<time>%s</time>\n"), GetCurrentTimeString().c_str()));
// Add column headers
if (!::DeleteFile(filepath.c_str()))
{
LogErrorString(Fmt(_T("DeleteFile(%s) failed: %s"),
- filepath.c_str(), GetSysError(GetLastError())));
+ filepath.c_str(), GetSysError(GetLastError()).c_str()));
}
}
// and change the filepath if everything works
if (!::DeleteFile(tempFilepath.c_str()))
{
LogErrorString(Fmt(_T("DeleteFile(%s) failed: %s"),
- tempFilepath.c_str(), GetSysError(GetLastError())));
+ tempFilepath.c_str(), GetSysError(GetLastError()).c_str()));
}
}
if (!::DeleteFile(filepath.c_str()))
{
LogErrorString(Fmt(_T("DeleteFile(%s) failed: %s"),
- filepath.c_str(), GetSysError(GetLastError())));
+ filepath.c_str(), GetSysError(GetLastError()).c_str()));
}
}
// and change the filepath if everything works
if (!::DeleteFile(tempFilepath.c_str()))
{
LogErrorString(Fmt(_T("DeleteFile(%s) failed: %s"),
- tempFilepath.c_str(), GetSysError(GetLastError())));
+ tempFilepath.c_str(), GetSysError(GetLastError()).c_str()));
}
}
if (!::DeleteFile(filepath.c_str()))
{
LogErrorString(Fmt(_T("DeleteFile(%s) failed: %s"),
- filepath.c_str(), GetSysError(GetLastError())));
+ filepath.c_str(), GetSysError(GetLastError()).c_str()));
}
}
// and change the filepath if everything works
if (!::DeleteFile(tempFilepath.c_str()))
{
LogErrorString(Fmt(_T("DeleteFile(%s) failed: %s"),
- tempFilepath.c_str(), GetSysError(GetLastError())));
+ tempFilepath.c_str(), GetSysError(GetLastError()).c_str()));
}
}
return TRUE;
if (hr != S_OK)
{
LogErrorString(Fmt(_T("DeleteFile(%s) failed: %s"),
- sIntermediateFilename.c_str(), GetSysError(hr)));
+ sIntermediateFilename.c_str(), GetSysError(hr).c_str()));
}
return S_OK;
}
if (tempPath.empty())
{
LogErrorString(Fmt(_T("CMainFrame::ReLinkVCProj() - couldn't get temppath: %s")
- , GetSysError(nerr)));
+ , GetSysError(nerr).c_str()));
return FALSE;
}
String tempFile = env_GetTempFileName(tempPath.c_str(), _T("_LT"), &nerr);
if (tempFile.empty())
{
LogErrorString(Fmt(_T("CMainFrame::ReLinkVCProj() - couldn't get tempfile: %s")
- , GetSysError(nerr)));
+ , GetSysError(nerr).c_str()));
return FALSE;
}
{
bSuccess = FALSE;
LogErrorString(Fmt(_T("CreateFile(%s) failed in files_openFileMapped: %s")
- , fileData->fileName, GetSysError(GetLastError())));
+ , fileData->fileName, GetSysError(GetLastError()).c_str()));
}
else
{
{
bSuccess = FALSE;
LogErrorString(Fmt(_T("CreateFileMapping(%s) failed: %s")
- , fileData->fileName, GetSysError(GetLastError())));
+ , fileData->fileName, GetSysError(GetLastError()).c_str()));
}
else
{
{
bSuccess = FALSE;
LogErrorString(Fmt(_T("MapViewOfFile(%s) failed: %s")
- , fileData->fileName, GetSysError(GetLastError())));
+ , fileData->fileName, GetSysError(GetLastError()).c_str()));
}
}
}