kernel: devrtc: fix use of uninitialized array in rtcextract

CID 156229: Uninitialized scalar variable (UNINIT)9.
uninit_use: Using uninitialized value bcdclock[0].
This commit is contained in:
Giacomo Tesio 2017-01-16 02:00:10 +01:00
parent 237b7709ae
commit 042e206d13
1 changed files with 3 additions and 0 deletions

View File

@ -118,6 +118,9 @@ rtcextract(void)
break; break;
} }
if(i == 10000)
return -1;
/* /*
* convert from BCD * convert from BCD
*/ */