MCPcopy Create free account
hub / github.com/go-git/go-git / Close

Method Close

storage/filesystem/object.go:646–661  ·  view source on GitHub ↗

Close closes all opened files.

()

Source from the content-addressed store, hash-verified

644
645// Close closes all opened files.
646func (s *ObjectStorage) Close() error {
647 var firstError error
648 if s.options.KeepDescriptors || s.options.MaxOpenDescriptors > 0 {
649 for _, packfile := range s.packfiles {
650 err := packfile.Close()
651 if firstError == nil && err != nil {
652 firstError = err
653 }
654 }
655 }
656
657 s.packfiles = nil
658 s.dir.Close()
659
660 return firstError
661}
662
663type lazyPackfilesIter struct {
664 hashes []plumbing.Hash

Callers

nothing calls this directly

Calls 1

CloseMethod · 0.65

Tested by

no test coverage detected