[libc][ctime] stime clear tv.tv_usec as zero
when using stime set rtc time, tv.tv_usec not 0,but always is 0xdeadbeef, make set time error
This commit is contained in:
parent
ba6a27c850
commit
517b5eb016
|
@ -383,6 +383,7 @@ int stime(const time_t *t)
|
|||
}
|
||||
|
||||
tv.tv_sec = *t;
|
||||
tv.tv_usec = 0;
|
||||
if (set_timeval(&tv) == RT_EOK)
|
||||
{
|
||||
return 0;
|
||||
|
|
Loading…
Reference in New Issue