summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--vendor.conf2
-rw-r--r--vendor/github.com/containers/storage/layers.go20
-rw-r--r--vendor/github.com/containers/storage/layers_ffjson.go2
3 files changed, 14 insertions, 10 deletions
diff --git a/vendor.conf b/vendor.conf
index e03ef9ea4..eba52c0d2 100644
--- a/vendor.conf
+++ b/vendor.conf
@@ -19,7 +19,7 @@ github.com/containers/image v2.0.0
github.com/vbauerster/mpb v3.3.4
github.com/mattn/go-isatty v0.0.4
github.com/VividCortex/ewma v1.1.1
-github.com/containers/storage v1.12.11
+github.com/containers/storage podman-v1.4.2-stable
github.com/containers/psgo v1.3.0
github.com/coreos/go-systemd v17
github.com/coreos/pkg v4
diff --git a/vendor/github.com/containers/storage/layers.go b/vendor/github.com/containers/storage/layers.go
index fb79238cd..cb975e2a0 100644
--- a/vendor/github.com/containers/storage/layers.go
+++ b/vendor/github.com/containers/storage/layers.go
@@ -362,7 +362,7 @@ func (r *layerStore) Load() error {
}
}
if shouldSave {
- return r.Save()
+ return r.saveLayers()
}
}
return err
@@ -393,6 +393,16 @@ func (r *layerStore) loadMounts() error {
}
func (r *layerStore) Save() error {
+ r.mountsLockfile.Lock()
+ defer r.mountsLockfile.Unlock()
+ defer r.mountsLockfile.Touch()
+ if err := r.saveLayers(); err != nil {
+ return err
+ }
+ return r.saveMounts()
+}
+
+func (r *layerStore) saveLayers() error {
if !r.IsReadWrite() {
return errors.Wrapf(ErrStoreIsReadOnly, "not allowed to modify the layer store at %q", r.layerspath())
}
@@ -408,13 +418,7 @@ func (r *layerStore) Save() error {
return err
}
defer r.Touch()
- if err := ioutils.AtomicWriteFile(rpath, jldata, 0600); err != nil {
- return err
- }
- r.mountsLockfile.Lock()
- defer r.mountsLockfile.Unlock()
- defer r.mountsLockfile.Touch()
- return r.saveMounts()
+ return ioutils.AtomicWriteFile(rpath, jldata, 0600)
}
func (r *layerStore) saveMounts() error {
diff --git a/vendor/github.com/containers/storage/layers_ffjson.go b/vendor/github.com/containers/storage/layers_ffjson.go
index 125b5d8c9..09b5d0f33 100644
--- a/vendor/github.com/containers/storage/layers_ffjson.go
+++ b/vendor/github.com/containers/storage/layers_ffjson.go
@@ -1,5 +1,5 @@
// Code generated by ffjson <https://github.com/pquerna/ffjson>. DO NOT EDIT.
-// source: layers.go
+// source: ./layers.go
package storage