Skip to content

Commit a728266

Browse files
authored
Merge pull request #108 from facchinm/agt_uninitialized
timer: agt: fix uninitialized memory
2 parents 5be4ea1 + c68b997 commit a728266

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

cores/arduino/FspTimer.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,10 +76,11 @@ class AGTimer {
7676
ext_cfg.trigger_edge = AGT_TRIGGER_EDGE_RISING;
7777

7878
cfg.p_extend = &ext_cfg;
79+
80+
memset(&ctrl, 0, sizeof(agt_instance_ctrl_t));
7981
}
8082
agt_extended_cfg_t ext_cfg;
8183
agt_instance_ctrl_t ctrl;
82-
8384
};
8485

8586

0 commit comments

Comments
 (0)