From 3cf4d3f4c7626a8d4236d203938b490190e02c97 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bj=C3=B6rn=20Jacke?= Date: Sun, 7 Jan 2024 05:09:58 +0100 Subject: [PATCH] time.c: fix ctime which was feeded with the mtime seconds This bug was introduced with 53a1d034f3e47ed3c in 2020. BUG: https://bugzilla.samba.org/show_bug.cgi?id=15550 Signed-off-by: Bjoern Jacke Reviewed-by: Volker Lendecke (cherry picked from commit 2df2e34c3c1ccf76bbcc78586cbbb6433b6d30d5) --- lib/util/time.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/util/time.c b/lib/util/time.c index c2a77d664d3..9393a754d73 100644 --- a/lib/util/time.c +++ b/lib/util/time.c @@ -1450,7 +1450,7 @@ struct timespec get_ctimespec(const struct stat *pst) { struct timespec ret; - ret.tv_sec = pst->st_mtime; + ret.tv_sec = pst->st_ctime; ret.tv_nsec = get_ctimensec(pst); return ret; } -- 2.41.0