mirror of
https://github.com/morgan9e/systemd
synced 2026-04-14 00:14:32 +09:00
portabled: load a bunch of libs before we fork off a dissector child processes
This commit is contained in:
@@ -29,6 +29,8 @@ executables += [
|
||||
'sources' : systemd_portabled_sources,
|
||||
'link_with' : portabled_link_with,
|
||||
'dependencies' : [
|
||||
libcryptsetup_cflags,
|
||||
libmount_cflags,
|
||||
libselinux_cflags,
|
||||
threads,
|
||||
],
|
||||
|
||||
@@ -12,6 +12,7 @@
|
||||
#include "chase.h"
|
||||
#include "conf-files.h"
|
||||
#include "copy.h"
|
||||
#include "cryptsetup-util.h"
|
||||
#include "data-fd-util.h"
|
||||
#include "dirent-util.h"
|
||||
#include "discover-image.h"
|
||||
@@ -28,6 +29,7 @@
|
||||
#include "glyph-util.h"
|
||||
#include "install.h"
|
||||
#include "iovec-util.h"
|
||||
#include "libmount-util.h"
|
||||
#include "log-context.h"
|
||||
#include "log.h"
|
||||
#include "loop-util.h"
|
||||
@@ -420,6 +422,10 @@ static int portable_extract_by_path(
|
||||
|
||||
BLOCK_SIGNALS(SIGCHLD);
|
||||
|
||||
/* Load some libraries before we fork workers off that want to use them */
|
||||
(void) dlopen_cryptsetup();
|
||||
(void) dlopen_libmount();
|
||||
|
||||
r = mkdtemp_malloc("/tmp/inspect-XXXXXX", &tmpdir);
|
||||
if (r < 0)
|
||||
return log_debug_errno(r, "Failed to create temporary directory: %m");
|
||||
|
||||
Reference in New Issue
Block a user