Fix enterMountNamespace() error handling. 86/232286/2
authorDariusz Michaluk <d.michaluk@samsung.com>
Wed, 29 Apr 2020 14:42:59 +0000 (16:42 +0200)
committerDariusz Michaluk <d.michaluk@samsung.com>
Thu, 30 Apr 2020 12:53:20 +0000 (14:53 +0200)
commitf29ad2910c7aa418f18bbfbf28e161c5a543acd7
treef24f254466b04537b60eefa8d8055026dbe28b86
parent964b061056128757a5fb67586a43a6015335b750
Fix enterMountNamespace() error handling.

There is a TOCTOU race condition between checking/entering app namespaces.
In this small time window, app can be killed,
so updating app namespace doesn't make sense, we can skip this step.

Change-Id: I27f8e0d5fed42a11b96dd79fc83b36be60aeca5e
src/common/include/mount-namespace.h
src/common/mount-namespace.cpp
src/common/worker.cpp