Fixes for toolchain 28 / gcc 12

This commit is contained in:
Willy-JL
2024-02-12 04:00:35 +00:00
parent d6cc1865ca
commit 374a30a281
5 changed files with 8 additions and 8 deletions

View File

@@ -252,7 +252,6 @@ void subghz_device_cc1101_ext_free() {
furi_assert(subghz_device_cc1101_ext != NULL);
furi_hal_spi_bus_handle_deinit(subghz_device_cc1101_ext->spi_bus_handle);
free(subghz_device_cc1101_ext);
// resetting the CS pins to floating
if(xtreme_settings.spi_nrf24_handle == SpiDefault || subghz_device_cc1101_ext->power_amp) {
@@ -261,6 +260,7 @@ void subghz_device_cc1101_ext_free() {
furi_hal_gpio_init_simple(&gpio_ext_pa4, GpioModeAnalog);
}
free(subghz_device_cc1101_ext);
subghz_device_cc1101_ext = NULL;
}

View File

@@ -48,7 +48,7 @@ bool xtreme_app_apply(XtremeApp* app) {
while(flipper_format_delete_key(file, "Frequency"))
;
FrequencyList_it(it, app->subghz_static_freqs);
for(uint i = 0; i < FrequencyList_size(app->subghz_static_freqs); i++) {
for(size_t i = 0; i < FrequencyList_size(app->subghz_static_freqs); i++) {
flipper_format_write_uint32(
file, "Frequency", FrequencyList_get(app->subghz_static_freqs, i), 1);
}
@@ -56,7 +56,7 @@ bool xtreme_app_apply(XtremeApp* app) {
if(!flipper_format_rewind(file)) break;
while(flipper_format_delete_key(file, "Hopper_frequency"))
;
for(uint i = 0; i < FrequencyList_size(app->subghz_hopper_freqs); i++) {
for(size_t i = 0; i < FrequencyList_size(app->subghz_hopper_freqs); i++) {
flipper_format_write_uint32(
file, "Hopper_frequency", FrequencyList_get(app->subghz_hopper_freqs, i), 1);
}

View File

@@ -68,11 +68,11 @@ void desktop_lock_menu_draw_callback(Canvas* canvas, void* model) {
canvas_set_color(canvas, ColorBlack);
canvas_set_font(canvas, FontBatteryPercent);
int x, y, w, h;
int8_t x, y, w, h;
bool selected, toggle;
bool enabled = false;
uint value = 0;
int total = 58;
uint8_t value = 0;
int8_t total = 58;
const Icon* icon = NULL;
for(size_t i = 0; i < DesktopLockMenuIndexTotalCount; ++i) {
selected = m->idx == i;

View File

@@ -28,7 +28,7 @@ void storage_settings_scene_sd_info_on_enter(void* context) {
double total_v = (double)sd_info.kb_total;
double free_v = (double)sd_info.kb_free;
char* units[] = {"KiB", "MiB", "GiB", "TiB"};
uint total_i, free_i;
uint8_t total_i, free_i;
for(total_i = 0; total_i < COUNT_OF(units); total_i++) {
if(total_v < 1024) break;
total_v /= 1024;