diff options
author | Stewart Smith <stewart@linux.vnet.ibm.com> | 2015-11-17 17:04:32 +1100 |
---|---|---|
committer | Stewart Smith <stewart@linux.vnet.ibm.com> | 2015-11-17 17:04:32 +1100 |
commit | 524031fab3af2aec916a92c88d66ff94f66cf570 (patch) | |
tree | 1232a43442b292e1256b5bb50a44a1b8a7b81387 /hw | |
parent | 14ed2b842f61cfc234a274c5f626d7d8f81e7aa9 (diff) | |
download | skiboot-524031fab3af2aec916a92c88d66ff94f66cf570.zip skiboot-524031fab3af2aec916a92c88d66ff94f66cf570.tar.gz skiboot-524031fab3af2aec916a92c88d66ff94f66cf570.tar.bz2 |
lpc-rtc: zero out struct tm before read
Picked up by static analysis. Never in a billion years would this
affect the real world.
Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com>
Diffstat (limited to 'hw')
-rw-r--r-- | hw/lpc-rtc.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/hw/lpc-rtc.c b/hw/lpc-rtc.c index 63124df..95506cd 100644 --- a/hw/lpc-rtc.c +++ b/hw/lpc-rtc.c @@ -119,6 +119,8 @@ static void lpc_init_time(void) struct tm tm; bool valid; + memset(&tm, 0, sizeof(tm)); + lock(&rtc_lock); /* If update is in progress, wait a bit */ |