From a1590fc74a15a2d838ef9231d0070ac8f79ef862 Mon Sep 17 00:00:00 2001 From: noproto Date: Tue, 8 Oct 2024 18:46:59 -0400 Subject: [PATCH] Fix memory leak in static encrypted attack --- .../main/nfc/scenes/nfc_scene_mf_classic_dict_attack.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/applications/main/nfc/scenes/nfc_scene_mf_classic_dict_attack.c b/applications/main/nfc/scenes/nfc_scene_mf_classic_dict_attack.c index 2691999b0..5ff014a1c 100644 --- a/applications/main/nfc/scenes/nfc_scene_mf_classic_dict_attack.c +++ b/applications/main/nfc/scenes/nfc_scene_mf_classic_dict_attack.c @@ -158,6 +158,9 @@ static void nfc_scene_mf_classic_dict_attack_prepare_view(NfcApp* instance) { furi_string_get_cstr(cuid_dict_path), KeysDictModeOpenExisting, sizeof(MfClassicKey)); + + furi_string_free(cuid_dict_path); + if(keys_dict_get_total_keys(instance->nfc_dict_context.dict) == 0) { keys_dict_free(instance->nfc_dict_context.dict); state = DictAttackStateUserDictInProgress;