diff options
-rw-r--r-- | data.cpp | 3 | ||||
-rw-r--r-- | openrecoveryscript.cpp | 2 |
2 files changed, 3 insertions, 2 deletions
@@ -556,8 +556,7 @@ void DataManager::SetBackupFolder() if (zip_path.size() < storage_path.size()) { SetValue(TW_ZIP_LOCATION_VAR, storage_path); } else { - zip_root= zip_path; - zip_root.resize(storage_path.size()); + zip_root = TWFunc::Get_Root_Path(zip_path); if (zip_root != storage_path) { LOGINFO("DataManager::SetBackupFolder zip path was %s changing to %s, %s\n", zip_path.c_str(), storage_path.c_str(), zip_root.c_str()); SetValue(TW_ZIP_LOCATION_VAR, storage_path); diff --git a/openrecoveryscript.cpp b/openrecoveryscript.cpp index bb472bf82..88b382974 100644 --- a/openrecoveryscript.cpp +++ b/openrecoveryscript.cpp @@ -98,6 +98,8 @@ int OpenRecoveryScript::run_script_file(void) { LOGINFO("command is: '%s' and ", command); val_start = script_line; val_start += cindex + 1; + if ((int) *val_start == 32) + val_start++; //get rid of space if ((int) *val_start == 51) val_start++; //get rid of = at the beginning strncpy(value, val_start, line_len - cindex - remove_nl); |