diff options
author | Chris Kay <chris.kay@arm.com> | 2018-06-14 11:27:17 +0100 |
---|---|---|
committer | ronald-cron-arm <39518861+ronald-cron-arm@users.noreply.github.com> | 2018-09-17 11:30:58 +0100 |
commit | eff37bd0548b96daf29ae02483dd8fc186ceefff (patch) | |
tree | ab1af60c68323a7c55e518a923df8d646decfc25 /module/timer | |
parent | e730d9b60dae0813d62dd07f2d9b248e4ba68ef3 (diff) |
misc: Fix possible use-before-initialization errors
All of these issues stem from assuming that passing a pointer-to-mutable
will initialize the object if it's not already initialized, but it's
unsafe to assume this is the case even if it is judged that the call
returned successfully, as the implementation may change at any point.
Change-Id: Ica114514429005b18d04efce2529e0a64a182525
Signed-off-by: Chris Kay <chris.kay@arm.com>
Diffstat (limited to 'module/timer')
-rw-r--r-- | module/timer/src/mod_timer.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/module/timer/src/mod_timer.c b/module/timer/src/mod_timer.c index 51789d92..a4183276 100644 --- a/module/timer/src/mod_timer.c +++ b/module/timer/src/mod_timer.c @@ -559,7 +559,7 @@ static int timer_bind(fwk_id_t id, unsigned int round) { int status; struct dev_ctx *ctx; - struct mod_timer_driver_api *driver; + struct mod_timer_driver_api *driver = NULL; unsigned int driver_module_idx; /* Nothing to do after the initial round. */ |