summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJonathan Lebon <jonathan@jlebon.com>2021-10-26 13:25:37 -0400
committerGitHub <noreply@github.com>2021-10-26 13:25:37 -0400
commit6e0165020a34edd593dbcac695f3e4d709197a5a (patch)
tree174d53e3d35a9c60d532acdbb5191ea00436e31f
parent1e6077af03a130d3f2c3d7e56e5b8f36c563b46e (diff)
parent7c17daad175a9e8bd876c3c548db0bdd4449b895 (diff)
downloadostree-6e0165020a34edd593dbcac695f3e4d709197a5a.tar.gz
Merge pull request #2473 from lucab/ups/prepare-root-less-global-mutable-state
-rw-r--r--src/switchroot/ostree-prepare-root.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/src/switchroot/ostree-prepare-root.c b/src/switchroot/ostree-prepare-root.c
index 20b8685d..46283f3f 100644
--- a/src/switchroot/ostree-prepare-root.c
+++ b/src/switchroot/ostree-prepare-root.c
@@ -81,9 +81,6 @@
#include "ostree-mount-util.h"
-/* Initialized early in main */
-static bool running_as_pid1;
-
static inline bool
sysroot_is_configured_ro (const char *sysroot)
{
@@ -175,7 +172,7 @@ main(int argc, char *argv[])
* - Quiet logging as there's no journal
* etc.
*/
- running_as_pid1 = (getpid () == 1);
+ bool running_as_pid1 = (getpid () == 1);
const char *root_arg = NULL;
bool we_mounted_proc = false;