mirror of
https://github.com/RT-Thread/rt-thread.git
synced 2025-10-18 18:34:20 +08:00
[libc] [ctime] fix rt_timespec_to_tick fun internal data overflow (#8198)
This commit is contained in:
@@ -710,7 +710,8 @@ RTM_EXPORT(clock_settime);
|
||||
int rt_timespec_to_tick(const struct timespec *time)
|
||||
{
|
||||
int tick;
|
||||
int nsecond, second;
|
||||
int second;
|
||||
long long nsecond;
|
||||
struct timespec tp = {0};
|
||||
|
||||
RT_ASSERT(time != RT_NULL);
|
||||
|
Reference in New Issue
Block a user