Is this the easiest way to delete everything between and including the two first quotes (if present) in an std::wstring
?
unsigned int firstQuotePos = logFileName.find_first_of(L"\"");
unsigned int secondQuotePos = logFileName.find_first_of(L"\"", firstQuotePos + 1);
if (firstQuotePos != std::wstring::npos && secondQuotePos != std::wstring::npos)
{
logFileName = std::wstring(logFileName.begin(), logFileName.begin() + firstQuotePos)
+ std::wstring(logFileName.begin() + secondQuotePos + 1, logFileName.end());
}