Closed S-trace closed 1 year ago
This breaks cross-platform compatibility; on macOS, there is no struct timespec st_mtim
; it's called struct timespec st_mtimespec
instead. fdupes
isn't ported to Windows but if it ever was, on MinGW compilters, there is no struct timespec
in sys/stat.h
. On NetBSD there is a fall-through that defines the nanosecond field as long st_mtimensec
instead of using struct timespec st_mtim
.
Add int is_first_timespec_newer(struct timespec first, struct timespec second).
Change time_t sorttime to struct timespec sorttimespec.
Change getmtime(char filename) and getctime(char filename) to return pointer to newly allocated struct timespec (must be passed to free() after use).