Remove unused function (#2484)

Also clean up some function prototypes.

Co-authored-by: Takeshi Nakatani <ggtakec@gmail.com>
This commit is contained in:
Andrew Gaul 2024-07-01 20:00:32 +05:30 committed by GitHub
parent a6637b29e6
commit ae28a110ab
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -33,7 +33,7 @@
//-------------------------------------------------------------------
// Utility
//-------------------------------------------------------------------
static inline void SetStatCacheTime(struct timespec& ts)
static void SetStatCacheTime(struct timespec& ts)
{
if(-1 == clock_gettime(static_cast<clockid_t>(CLOCK_MONOTONIC_COARSE), &ts)){
S3FS_PRN_CRIT("clock_gettime failed: %d", errno);
@ -41,13 +41,7 @@ static inline void SetStatCacheTime(struct timespec& ts)
}
}
static inline void InitStatCacheTime(struct timespec& ts)
{
ts.tv_sec = 0;
ts.tv_nsec = 0;
}
static inline int CompareStatCacheTime(const struct timespec& ts1, const struct timespec& ts2)
static int CompareStatCacheTime(const struct timespec& ts1, const struct timespec& ts2)
{
// return -1: ts1 < ts2
// 0: ts1 == ts2
@ -66,7 +60,7 @@ static inline int CompareStatCacheTime(const struct timespec& ts1, const struct
return 0;
}
static inline bool IsExpireStatCacheTime(const struct timespec& ts, const time_t& expire)
static bool IsExpireStatCacheTime(const struct timespec& ts, time_t expire)
{
struct timespec nowts;
SetStatCacheTime(nowts);