core: only attempt to deserialize state from LUO on boot
Avoid trying to query for our LUO session on reexec/softreboot/reload/etc.
Currently /dev/liveupdate is only accessible to root so it's not a big
issue, but this might change in the future, so make sure nobody can
play games with us.
Follow-up for 257c35c1a3
This commit is contained in:
+4
-2
@@ -2194,8 +2194,10 @@ int manager_startup(Manager *m, FILE *serialization, FDSet *fds, Hashmap *named_
|
||||
m->soft_reboots_count++;
|
||||
|
||||
/* If a LUO (Live Update Orchestrator) session from a previous kexec is available, restore
|
||||
* preserved file descriptors into the appropriate service fd stores now, before coldplug. */
|
||||
(void) manager_luo_restore_fd_stores(m);
|
||||
* preserved file descriptors into the appropriate service fd stores now, before coldplug.
|
||||
* Only do this when booting up (i.e., skip on reexec/soft reboot/etc.) */
|
||||
if (m->previous_objective < 0)
|
||||
(void) manager_luo_restore_fd_stores(m);
|
||||
|
||||
/* Pick up fds passed via the LISTEN_FDS=/LISTEN_FDNAMES= protocol that are tagged with a
|
||||
* unit id ("unit-id|fdname"), and route them into the matching unit's fd store. Untagged
|
||||
|
||||
Reference in New Issue
Block a user