Skip to content

Commit 1793b61

Browse files
authored
Gotta zerolize the structs! (#972)
1 parent 0186844 commit 1793b61

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lib/hardware/fnSystem.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -645,7 +645,7 @@ int SystemManager::get_sio_voltage()
645645
}
646646
#else
647647
adc_oneshot_unit_handle_t adc1_handle;
648-
adc_oneshot_unit_init_cfg_t init_config1;
648+
adc_oneshot_unit_init_cfg_t init_config1 {};
649649
init_config1.unit_id = ADC_UNIT_1;
650650
init_config1.ulp_mode = ADC_ULP_MODE_DISABLE;
651651

@@ -669,7 +669,7 @@ int SystemManager::get_sio_voltage()
669669
#endif
670670

671671
#if ADC_CALI_SCHEME_LINE_FITTING_SUPPORTED
672-
adc_cali_line_fitting_config_t cali_config;
672+
adc_cali_line_fitting_config_t cali_config {};
673673
cali_config.unit_id = ADC_UNIT_1;
674674
cali_config.atten = ADC_ATTEN_11db;
675675
cali_config.bitwidth = ADC_WIDTH_12Bit;

0 commit comments

Comments
 (0)