M*LIB: non-inlined strings, FuriString primitive (#1795)
* Quicksave 1 * Header stage complete * Source stage complete * Lint & merge fixes * Includes * Documentation step 1 * FBT: output free size considering BT STACK * Documentation step 2 * py lint * Fix music player plugin * unit test stage 1: string allocator, mem, getters, setters, appends, compare, search. * unit test: string equality * unit test: string replace * unit test: string start_with, end_with * unit test: string trim * unit test: utf-8 * Rename * Revert fw_size changes * Simplify CLI backspace handling * Simplify CLI character insert * Merge fixes * Furi: correct filenaming and spelling * Bt: remove furi string include Co-authored-by: Aleksandr Kutuzov <alleteam@gmail.com>
This commit is contained in:
@@ -35,10 +35,10 @@ static void
|
||||
Updater* updater_alloc(const char* arg) {
|
||||
Updater* updater = malloc(sizeof(Updater));
|
||||
if(arg && strlen(arg)) {
|
||||
string_init_set_str(updater->startup_arg, arg);
|
||||
string_replace_str(updater->startup_arg, ANY_PATH(""), EXT_PATH(""));
|
||||
updater->startup_arg = furi_string_alloc_set(arg);
|
||||
furi_string_replace(updater->startup_arg, ANY_PATH(""), EXT_PATH(""));
|
||||
} else {
|
||||
string_init(updater->startup_arg);
|
||||
updater->startup_arg = furi_string_alloc();
|
||||
}
|
||||
|
||||
updater->storage = furi_record_open(RECORD_STORAGE);
|
||||
@@ -94,7 +94,7 @@ Updater* updater_alloc(const char* arg) {
|
||||
void updater_free(Updater* updater) {
|
||||
furi_assert(updater);
|
||||
|
||||
string_clear(updater->startup_arg);
|
||||
furi_string_free(updater->startup_arg);
|
||||
if(updater->update_task) {
|
||||
update_task_set_progress_cb(updater->update_task, NULL, NULL);
|
||||
update_task_free(updater->update_task);
|
||||
|
Reference in New Issue
Block a user