From ae76f453397f445e3a6c7d7db6cbf1f891ef4cb7 Mon Sep 17 00:00:00 2001 From: MX <10697207+xMasterX@users.noreply.github.com> Date: Fri, 7 Oct 2022 22:13:45 +0300 Subject: [PATCH] sub brute fixes --- applications/plugins/subbrute/helpers/subbrute_worker.c | 6 +++--- applications/plugins/subbrute/scenes/subbrute_scene_start.c | 2 +- applications/plugins/subbrute/subbrute_device.c | 6 +++--- applications/plugins/subbrute/views/subbrute_attack_view.c | 6 +++++- 4 files changed, 12 insertions(+), 8 deletions(-) diff --git a/applications/plugins/subbrute/helpers/subbrute_worker.c b/applications/plugins/subbrute/helpers/subbrute_worker.c index 9e5c56d79..01df8c4ba 100644 --- a/applications/plugins/subbrute/helpers/subbrute_worker.c +++ b/applications/plugins/subbrute/helpers/subbrute_worker.c @@ -113,7 +113,7 @@ bool subbrute_worker_start( instance->worker_running = res; #ifdef FURI_DEBUG - FURI_LOG_I(TAG, "Frequency: %d", frequency); + FURI_LOG_I(TAG, "Frequency: %ld", frequency); #endif instance->preset = preset; if(res) { @@ -206,7 +206,7 @@ bool subbrute_worker_init_manual_transmit( #ifdef FURI_DEBUG FURI_LOG_D( TAG, - "subbrute_worker_init_manual_transmit. frequency: %d, protocol: %s", + "subbrute_worker_init_manual_transmit. frequency: %ld, protocol: %s", frequency, protocol_name); #endif @@ -254,7 +254,7 @@ bool subbrute_worker_init_manual_transmit( }*/ #ifdef FURI_DEBUG - FURI_LOG_I(TAG, "Frequency: %d", frequency); + FURI_LOG_I(TAG, "Frequency: %ld", frequency); #endif instance->transmitter = subghz_transmitter_alloc_init( diff --git a/applications/plugins/subbrute/scenes/subbrute_scene_start.c b/applications/plugins/subbrute/scenes/subbrute_scene_start.c index fe3a5d8b4..9c572db3c 100644 --- a/applications/plugins/subbrute/scenes/subbrute_scene_start.c +++ b/applications/plugins/subbrute/scenes/subbrute_scene_start.c @@ -42,7 +42,7 @@ bool subbrute_scene_start_on_event(void* context, SceneManagerEvent event) { if(event.type == SceneManagerEventTypeCustom) { #ifdef FURI_DEBUG - FURI_LOG_D(TAG, "Event: %d", event.event); + FURI_LOG_D(TAG, "Event: %ld", event.event); #endif if(event.event == SubBruteCustomEventTypeMenuSelected) { SubBruteAttacks attack = subbrute_main_view_get_index(instance->view_main); diff --git a/applications/plugins/subbrute/subbrute_device.c b/applications/plugins/subbrute/subbrute_device.c index e335438a4..10d7a798d 100644 --- a/applications/plugins/subbrute/subbrute_device.c +++ b/applications/plugins/subbrute/subbrute_device.c @@ -229,7 +229,7 @@ bool subbrute_device_create_packet_parsed(SubBruteDevice* instance, uint64_t ste } #ifdef FURI_DEBUG - FURI_LOG_D(TAG, "candidate: %s, step: %d", furi_string_get_cstr(candidate), step); + FURI_LOG_D(TAG, "candidate: %s, step: %lld", furi_string_get_cstr(candidate), step); #endif if(small) { @@ -537,7 +537,7 @@ uint8_t subbrute_device_load_from_file(SubBruteDevice* instance, FuriString* fil } instance->bit = temp_data32; #ifdef FURI_DEBUG - FURI_LOG_D(TAG, "Bit: %d", instance->bit); + FURI_LOG_D(TAG, "Bit: %ld", instance->bit); #endif } @@ -570,7 +570,7 @@ uint8_t subbrute_device_load_from_file(SubBruteDevice* instance, FuriString* fil // Repeat if(flipper_format_read_uint32(fff_data_file, "Repeat", &temp_data32, 1)) { #ifdef FURI_DEBUG - FURI_LOG_D(TAG, "Repeat: %d", temp_data32); + FURI_LOG_D(TAG, "Repeat: %ld", temp_data32); #endif instance->repeat = temp_data32; } else { diff --git a/applications/plugins/subbrute/views/subbrute_attack_view.c b/applications/plugins/subbrute/views/subbrute_attack_view.c index 562c30131..b78aeaa84 100644 --- a/applications/plugins/subbrute/views/subbrute_attack_view.c +++ b/applications/plugins/subbrute/views/subbrute_attack_view.c @@ -248,7 +248,11 @@ void subbrute_attack_view_init_values( bool is_attacking) { #ifdef FURI_DEBUG FURI_LOG_D( - TAG, "init, index: %d, max_value: %d, current_step: %d", index, max_value, current_step); + TAG, + "init, index: %d, max_value: %lld, current_step: %lld", + index, + max_value, + current_step); #endif with_view_model( instance->view, (SubBruteAttackViewModel * model) {