mirror of
https://github.com/apache/nuttx.git
synced 2026-06-06 16:50:55 +08:00
RTC driver: Needs to initialize state structure to zero on initalization
This commit is contained in:
+1
-1
Submodule arch updated: c71c24971d...c4f77e7d87
@@ -577,7 +577,7 @@ int rtc_initialize(int minor, FAR struct rtc_lowerhalf_s *lower)
|
||||
|
||||
/* Allocate an upper half container structure */
|
||||
|
||||
upper = (FAR struct rtc_upperhalf_s *)kmm_malloc(sizeof(struct rtc_upperhalf_s));
|
||||
upper = (FAR struct rtc_upperhalf_s *)kmm_zalloc(sizeof(struct rtc_upperhalf_s));
|
||||
if (!upper)
|
||||
{
|
||||
return -ENOMEM;
|
||||
|
||||
Reference in New Issue
Block a user