mirror of
https://github.com/AuxXxilium/kmod.git
synced 2025-01-18 18:07:26 +07:00
tools/modinfo: exit non-zero on module not found
This commit is contained in:
parent
b30a71b8e8
commit
5f85a133f8
@ -279,6 +279,12 @@ static int modinfo_alias_do(struct kmod_ctx *ctx, const char *alias)
|
||||
LOG("Module alias %s not found.\n", alias);
|
||||
return err;
|
||||
}
|
||||
|
||||
if (list == NULL) {
|
||||
LOG("Module %s not found.\n", alias);
|
||||
return -ENOENT;
|
||||
}
|
||||
|
||||
kmod_list_foreach(l, list) {
|
||||
struct kmod_module *mod = kmod_module_get_module(l);
|
||||
int r = modinfo_do(mod);
|
||||
|
Loading…
Reference in New Issue
Block a user