- fix path to firmware settings file (fix [#1354]);
This commit is contained in:
parent
3d8f138874
commit
d6db1f7e96
|
@ -601,8 +601,11 @@ std::string CFIRMWARE::GetExternalFilePath()
|
|||
{
|
||||
std::string fwPath = CommonSettings.Firmware;
|
||||
std::string fwFileName = Path::GetFileNameFromPathWithoutExt(fwPath);
|
||||
std::string configPath = path.pathToBattery;
|
||||
std::string finalPath = configPath + DIRECTORY_DELIMITER_CHAR + fwFileName + FILE_EXT_DELIMITER_CHAR + FW_CONFIG_FILE_EXT;
|
||||
char configPath[MAX_PATH] = {0};
|
||||
path.getpath(path.BATTERY, configPath);
|
||||
if (configPath[strlen(configPath)-1] == DIRECTORY_DELIMITER_CHAR)
|
||||
configPath[strlen(configPath)-1] = 0;
|
||||
std::string finalPath = std::string(configPath) + DIRECTORY_DELIMITER_CHAR + fwFileName + FILE_EXT_DELIMITER_CHAR + FW_CONFIG_FILE_EXT;
|
||||
|
||||
return finalPath;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue