combine homepath and homedrive into single line

This commit is contained in:
Shelley Vohr 2017-10-25 11:46:51 -04:00
parent 1e8bdc15e2
commit 3c1c5a4099
No known key found for this signature in database
GPG key ID: F13993A75599653C

View file

@ -168,9 +168,8 @@ BrowserMainParts::~BrowserMainParts() {
void OverrideAppLogsPath() { void OverrideAppLogsPath() {
#if defined(OS_WIN) #if defined(OS_WIN)
std::wstring app_name = base::UTF8ToWide(GetApplicationName()); std::wstring app_name = base::UTF8ToWide(GetApplicationName());
std::wstring drive = _wgetenv(L"HOMEDRIVE")); std::wstring home = _wgetenv(L"HOMEDRIVE") + "\\" +_wgetenv(L"HOMEPATH");
std::wstring path = _wgetenv(L"HOMEPATH")); std::wstring log_path = home + L"\\AppData\\Roaming\\";
std::wstring log_path = drive + "\\" + path + L"\\AppData\\Roaming\\";
std::wstring app_log_path = log_path + app_name + L"\\logs"; std::wstring app_log_path = log_path + app_name + L"\\logs";
#else #else
std::string app_name = GetApplicationName(); std::string app_name = GetApplicationName();