systemd/0440-manager-add-one-more-assert.patch
Jan Macku 484e7cdd90 systemd-252-21
Resolves: RHEL-13199,RHEL-5988,RHEL-6090
2023-12-11 15:54:06 +01:00

26 lines
744 B
Diff

From efe1737efae0950b7ded32d9c5e1a9cfaea7296b Mon Sep 17 00:00:00 2001
From: Lennart Poettering <lennart@poettering.net>
Date: Mon, 2 Jan 2023 15:00:05 +0100
Subject: [PATCH] manager: add one more assert()
(cherry picked from commit 7fa49280bc33ba5135228401fb24dce0de5f9195)
Related: RHEL-6090
---
src/core/manager.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/src/core/manager.c b/src/core/manager.c
index 657263eb73..6371810ce3 100644
--- a/src/core/manager.c
+++ b/src/core/manager.c
@@ -806,6 +806,8 @@ static int manager_find_credentials_dirs(Manager *m) {
}
void manager_set_switching_root(Manager *m, bool switching_root) {
+ assert(m);
+
m->switching_root = MANAGER_IS_SYSTEM(m) && switching_root;
}