summaryrefslogtreecommitdiff
path: root/libpod
diff options
context:
space:
mode:
authorMatthew Heon <matthew.heon@gmail.com>2018-09-25 10:11:54 -0400
committerMatthew Heon <matthew.heon@pm.me>2019-01-04 09:51:09 -0500
commit31df5e0e85d26c008f7781ec94e1c5c9e8c7238d (patch)
tree3c226e7e3e71ca825ce2cd363c2b4d0c7ba2de2f /libpod
parent625c7e18ef2b7f47a853c42f1a07fec730dbc91e (diff)
downloadpodman-31df5e0e85d26c008f7781ec94e1c5c9e8c7238d.tar.gz
podman-31df5e0e85d26c008f7781ec94e1c5c9e8c7238d.tar.bz2
podman-31df5e0e85d26c008f7781ec94e1c5c9e8c7238d.zip
Ensure different error messages and creating/opening locks
Signed-off-by: Matthew Heon <matthew.heon@gmail.com>
Diffstat (limited to 'libpod')
-rw-r--r--libpod/runtime.go10
1 files changed, 6 insertions, 4 deletions
diff --git a/libpod/runtime.go b/libpod/runtime.go
index a39547a43..ae4b77bd4 100644
--- a/libpod/runtime.go
+++ b/libpod/runtime.go
@@ -541,11 +541,14 @@ func makeRuntime(runtime *Runtime) (err error) {
}
if doRefresh {
manager, err = lock.NewSHMLockManager(lockPath, runtime.config.NumLocks)
+ if err != nil {
+ return errors.Wrapf(err, "error creating SHM locks for libpod")
+ }
} else {
manager, err = lock.OpenSHMLockManager(lockPath, runtime.config.NumLocks)
- }
- if err != nil {
- return errors.Wrapf(err, "error initializing SHM locking")
+ if err != nil {
+ return errors.Wrapf(err, "error opening libpod SHM locks")
+ }
}
runtime.lockManager = manager
@@ -720,7 +723,6 @@ func makeRuntime(runtime *Runtime) (err error) {
if err2 := runtime.refresh(runtimeAliveFile); err2 != nil {
return err2
}
-
}
}