mirror of
https://github.com/containers/skopeo.git
synced 2025-09-06 09:12:25 +00:00
Bump github.com/containers/common from 0.38.1 to 0.38.4
Bumps [github.com/containers/common](https://github.com/containers/common) from 0.38.1 to 0.38.4. - [Release notes](https://github.com/containers/common/releases) - [Commits](https://github.com/containers/common/compare/v0.38.1...v0.38.4) Signed-off-by: dependabot[bot] <support@github.com> Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
This commit is contained in:
committed by
Daniel J Walsh
parent
4e57679c9a
commit
91d9ccf5e5
13
vendor/github.com/containers/storage/containers.go
generated
vendored
13
vendor/github.com/containers/storage/containers.go
generated
vendored
@@ -5,6 +5,7 @@ import (
|
||||
"io/ioutil"
|
||||
"os"
|
||||
"path/filepath"
|
||||
"sync"
|
||||
"time"
|
||||
|
||||
"github.com/containers/storage/pkg/idtools"
|
||||
@@ -113,6 +114,7 @@ type containerStore struct {
|
||||
byid map[string]*Container
|
||||
bylayer map[string]*Container
|
||||
byname map[string]*Container
|
||||
loadMut sync.Mutex
|
||||
}
|
||||
|
||||
func copyContainer(c *Container) *Container {
|
||||
@@ -615,3 +617,14 @@ func (r *containerStore) TouchedSince(when time.Time) bool {
|
||||
func (r *containerStore) Locked() bool {
|
||||
return r.lockfile.Locked()
|
||||
}
|
||||
|
||||
func (r *containerStore) ReloadIfChanged() error {
|
||||
r.loadMut.Lock()
|
||||
defer r.loadMut.Unlock()
|
||||
|
||||
modified, err := r.Modified()
|
||||
if err == nil && modified {
|
||||
return r.Load()
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
Reference in New Issue
Block a user