aboutsummaryrefslogtreecommitdiff
path: root/refstore/files/store.go
diff options
context:
space:
mode:
authorGravatar Runxi Yu2026-03-22 22:07:39 +0000
committerGravatar Runxi Yu2026-03-22 22:07:39 +0000
commit7ddaf1eb2fde11a9e07df0215646c1dca08ccc50 (patch)
treeec1096bd8229fa0a3c3272e2a52e60bff0d73797 /refstore/files/store.go
parentobjectstore/loose, receivepack/service, repository: Lint whitespace (diff)
signatureNo signature
refstore, repository: Ownership/lifetimes fix v0.1.87
Diffstat (limited to 'refstore/files/store.go')
-rw-r--r--refstore/files/store.go3
1 files changed, 2 insertions, 1 deletions
diff --git a/refstore/files/store.go b/refstore/files/store.go
index 6091c000..378c0af0 100644
--- a/refstore/files/store.go
+++ b/refstore/files/store.go
@@ -14,7 +14,8 @@ import (
// Store reads and writes one Git files ref namespace rooted at one repository
// gitdir plus its commondir.
//
-// Store owns both roots and closes them in Close.
+// Store borrows gitRoot and owns commonRoot. Close releases only resources
+// opened by the store itself.
type Store struct {
gitRoot *os.Root
commonRoot *os.Root