diff options
author | Matthew Heon <matthew.heon@gmail.com> | 2018-09-25 10:11:54 -0400 |
---|---|---|
committer | Matthew Heon <matthew.heon@pm.me> | 2019-01-04 09:51:09 -0500 |
commit | 31df5e0e85d26c008f7781ec94e1c5c9e8c7238d (patch) | |
tree | 3c226e7e3e71ca825ce2cd363c2b4d0c7ba2de2f /libpod | |
parent | 625c7e18ef2b7f47a853c42f1a07fec730dbc91e (diff) | |
download | podman-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.go | 10 |
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 } - } } |