mirror of
https://git.hardenedbsd.org/hardenedbsd/HardenedBSD.git
synced 2025-01-11 00:41:30 +01:00
Add a #ifdef _THREAD_SAFE around ctime_r
This commit is contained in:
parent
5f03edf130
commit
4f6eb9ceed
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=35331
@ -1345,6 +1345,7 @@ const time_t * const timep;
|
||||
return asctime(localtime(timep));
|
||||
}
|
||||
|
||||
#ifdef _THREAD_SAFE
|
||||
char *
|
||||
ctime_r(timep, buf)
|
||||
const time_t * const timep;
|
||||
@ -1353,6 +1354,7 @@ char *buf;
|
||||
struct tm tm;
|
||||
return asctime_r(localtime_r(timep, &tm), buf);
|
||||
}
|
||||
#endif
|
||||
|
||||
/*
|
||||
** Adapted from code provided by Robert Elz, who writes:
|
||||
|
Loading…
Reference in New Issue
Block a user