Skip to content

Commit 9acf6f7

Browse files
committed
fix: init RtcHandle.instance
else this prevent isConfigured(void) to return correct value. Signed-off-by: Frederic Pillon <frederic.pillon@st.com>
1 parent 2d11284 commit 9acf6f7

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/rtc.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ extern "C" {
5656
/* Private define ------------------------------------------------------------*/
5757
/* Private macro -------------------------------------------------------------*/
5858
/* Private variables ---------------------------------------------------------*/
59-
static RTC_HandleTypeDef RtcHandle = {0};
59+
static RTC_HandleTypeDef RtcHandle = {.Instance = RTC};
6060
static voidCallbackPtr RTCUserCallback = NULL;
6161
static void *callbackUserData = NULL;
6262
#ifdef RTC_ALARM_B

0 commit comments

Comments
 (0)