You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
calculate-overlay/profiles/templates/3.6/6_ac_install_patch/sys-kernel/dracut/dracut-048-skip_modules_wit...

23 lines
984 B

# Calculate format=diff merge(sys-kernel/dracut)=>048,049
commit e331e06a3910ef3fe6837f3e93a48123a7cc822b
Author: Harald Hoyer <harald@redhat.com>
Date: Wed Jul 18 12:41:01 2018 +0200
dracut-install: skip modules with empty path
if kmod_module_get_path(module) returns NULL, skip the module
diff --git a/install/dracut-install.c b/install/dracut-install.c
index 001225b4..88bca1d4 100644
--- a/install/dracut-install.c
+++ b/install/dracut-install.c
@@ -1244,7 +1244,7 @@ static int install_dependent_modules(struct kmod_list *modlist)
path = kmod_module_get_path(mod);
name = kmod_module_get_name(mod);
- if (arg_mod_filter_noname && (regexec(&mod_filter_noname, name, 0, NULL, 0) == 0)) {
+ if ((path == NULL) || (arg_mod_filter_noname && (regexec(&mod_filter_noname, name, 0, NULL, 0) == 0))) {
kmod_module_unref(mod);
continue;
}