Don't throw error on clenaup ipc mounts if it does not exists

Signed-off-by: Lei Jitang <leijitang@huawei.com>
Upstream-commit: 5bd1786387bdb0af2e665fecde3ac08f8db61008
Component: engine
This commit is contained in:
Lei Jitang
2016-04-06 07:34:31 -04:00
parent 476df032fb
commit 0894026fe2

View File

@ -214,7 +214,7 @@ func (container *Container) UnmountIpcMounts(unmount func(pth string) error) {
logrus.Error(err)
warnings = append(warnings, err.Error())
} else if shmPath != "" {
if err := unmount(shmPath); err != nil {
if err := unmount(shmPath); err != nil && !os.IsNotExist(err) {
warnings = append(warnings, fmt.Sprintf("failed to umount %s: %v", shmPath, err))
}