mirror of
https://github.com/espressif/esp-idf.git
synced 2025-07-31 19:24:33 +02:00
newlib: Avoid deprecation warning calling system_get_time() from system_relative_time()
This commit is contained in:
committed by
Angus Gratton
parent
73b3ae8a2d
commit
f8339fc1bd
@@ -229,7 +229,11 @@ uint32_t system_get_current_time(void) __attribute__((alias("system_get_time")))
|
||||
|
||||
uint32_t system_relative_time(uint32_t current_time)
|
||||
{
|
||||
return system_get_time() - current_time;
|
||||
#if defined( WITH_FRC1 ) || defined( WITH_RTC )
|
||||
return get_time_since_boot() - current_time;
|
||||
#else
|
||||
return 0;
|
||||
#endif
|
||||
}
|
||||
|
||||
uint64_t system_get_rtc_time(void)
|
||||
|
Reference in New Issue
Block a user