mirror of
https://github.com/jart/cosmopolitan.git
synced 2025-01-31 19:43:32 +00:00
6a145a9262
- Add hierarchical auto-completion to redbean's repl - Fetch latest localtime() and strftime() from Eggert - Shave a few milliseconds off redbean start latency - Fix redbean repl with multi-line statements - Make the Lua unix module code more elegant - Harden Lua data structure serialization
9 lines
254 B
C
9 lines
254 B
C
#include "libc/calls/weirdtypes.h"
|
|
#include "libc/time/struct/tm.h"
|
|
#include "libc/time/time.h"
|
|
|
|
char *ctime_r(const time_t *timep, char *buf) {
|
|
struct tm mytm;
|
|
struct tm *tmp = localtime_r(timep, &mytm);
|
|
return tmp ? asctime_r(tmp, buf) : NULL;
|
|
}
|