aboutsummaryrefslogtreecommitdiffhomepage
path: root/internal
diff options
context:
space:
mode:
Diffstat (limited to 'internal')
-rw-r--r--internal/rosa/state.go5
1 files changed, 5 insertions, 0 deletions
diff --git a/internal/rosa/state.go b/internal/rosa/state.go
index c236ee6d..e0537b6c 100644
--- a/internal/rosa/state.go
+++ b/internal/rosa/state.go
@@ -20,6 +20,7 @@ import (
"strings"
"sync"
"sync/atomic"
+ "time"
"unique"
"unsafe"
@@ -1436,6 +1437,9 @@ func (s *S) setSource(p []byte, version string) {
s.DropCaches(s.Arch(), s.Flags())
}
+// archiveTime is the hardcoded time written to every header time field.
+var archiveTime = time.Unix(0, 0)
+
// SetSource overrides the hakurei-source package with a cached tarball of fsys.
// The resulting IR is curable on the daemon. Must not be used concurrently with
// any other method.
@@ -1482,6 +1486,7 @@ func (s *S) SetSource(fsys fs.FS) error {
if h, err = tar.FileInfoHeader(fi, linkname); err != nil {
return err
}
+ h.AccessTime, h.ChangeTime, h.ModTime = archiveTime, archiveTime, archiveTime
h.Name = path
if err = tw.WriteHeader(h); err != nil {