[FL-2297, FL-2289] Power info command, Validator fixes (#1097)

* Power info command, validator fixes
* strdup in validator, fix memory leak
* furi_hal_crypto fixed again
* FuriHal: limit ARR and CC in speaker hal
* FuriHal: LL_TIM_DisableAllOutputs in speaker stop
* Rpc: fix memory leak in screen streaming
* Get rid of crypto_enable/crypto_disable

Co-authored-by: Aleksandr Kutuzov <alleteam@gmail.com>
This commit is contained in:
Nikolay Minaylov
2022-04-07 18:00:45 +03:00
committed by GitHub
parent 02b9cf90d5
commit d635890342
24 changed files with 372 additions and 55 deletions

View File

@@ -400,12 +400,14 @@ bool subghz_rename_file(SubGhz* subghz) {
string_init_printf(
new_path, "%s/%s%s", SUBGHZ_APP_FOLDER, subghz->file_name, SUBGHZ_APP_EXTENSION);
FS_Error fs_result =
storage_common_rename(storage, string_get_cstr(old_path), string_get_cstr(new_path));
if(string_cmp(old_path, new_path) != 0) {
FS_Error fs_result =
storage_common_rename(storage, string_get_cstr(old_path), string_get_cstr(new_path));
if(fs_result != FSE_OK) {
dialog_message_show_storage_error(subghz->dialogs, "Cannot rename\n file/directory");
ret = false;
if(fs_result != FSE_OK) {
dialog_message_show_storage_error(subghz->dialogs, "Cannot rename\n file/directory");
ret = false;
}
}
string_clear(old_path);