From bc54aa9fe40d6d1ffa6f80a1e04a18689ddbc54c Mon Sep 17 00:00:00 2001 From: Dmitry Vyukov Date: Fri, 9 Jan 2026 14:39:39 +0100 Subject: pkg/osutil: fix CreationTime We return Ctime from CreationTime. But "C" does not stand for "creation", it stands for "status change" (inode update). It may or may not be the creation time. Use Btime (birth time) for creation time. Fixes #6547 --- pkg/manager/crash.go | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'pkg/manager') diff --git a/pkg/manager/crash.go b/pkg/manager/crash.go index a62ec8280..e537cdf60 100644 --- a/pkg/manager/crash.go +++ b/pkg/manager/crash.go @@ -235,7 +235,7 @@ func (cs *CrashStore) BugInfo(id string, full bool) (*BugInfo, error) { if err != nil { return nil, err } - stat, err := os.Stat(filepath.Join(dir, "description")) + ret.FirstTime, ret.LastTime, err = osutil.FileTimes(filepath.Join(dir, "description")) if err != nil { return nil, err } @@ -250,8 +250,6 @@ func (cs *CrashStore) BugInfo(id string, full bool) (*BugInfo, error) { } } - ret.FirstTime = osutil.CreationTime(stat) - ret.LastTime = stat.ModTime() files, err := osutil.ListDir(dir) if err != nil { return nil, err -- cgit mrf-deployment