From 2d8aadff21d756ab37433713d667a0e6a8f99fcb Mon Sep 17 00:00:00 2001 From: Liu Jicong Date: Tue, 12 Oct 2021 16:30:40 +0800 Subject: [PATCH] put taosGetTimestampSec in osTime --- source/common/src/ttime.c | 2 -- source/os/src/osTime.c | 2 ++ 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/source/common/src/ttime.c b/source/common/src/ttime.c index 0f15dcc13b..0aa2aef4be 100644 --- a/source/common/src/ttime.c +++ b/source/common/src/ttime.c @@ -94,8 +94,6 @@ static int32_t (*parseLocaltimeFp[]) (char* timestr, int64_t* time, int32_t time parseLocaltimeWithDst }; -int32_t taosGetTimestampSec() { return (int32_t)time(NULL); } - int32_t taosParseTime(char* timestr, int64_t* time, int32_t len, int32_t timePrec, int8_t day_light) { /* parse datatime string in with tz */ if (strnchr(timestr, 'T', len, false) != NULL) { diff --git a/source/os/src/osTime.c b/source/os/src/osTime.c index bf0585e86d..7c655c0251 100644 --- a/source/os/src/osTime.c +++ b/source/os/src/osTime.c @@ -63,4 +63,6 @@ FORCE_INLINE int32_t taosGetTimeOfDay(struct timeval *tv) { return gettimeofday(tv, NULL); } +int32_t taosGetTimestampSec() { return (int32_t)time(NULL); } + #endif -- GitLab