mirror of
https://github.com/SerenityOS/serenity
synced 2024-07-21 18:15:58 +00:00
Kernel: Don't populate the ACPI SysFS directory with a disabled ACPI
This would cause a nullptr dereference on ACPI::Parser::the().
This commit is contained in:
parent
57ba67ed2a
commit
3945e239e1
|
@ -22,7 +22,8 @@ UNMAP_AFTER_INIT void FirmwareSysFSDirectory::initialize()
|
|||
void FirmwareSysFSDirectory::create_components()
|
||||
{
|
||||
m_components.append(BIOSSysFSDirectory::must_create(*this));
|
||||
m_components.append(ACPI::ACPISysFSDirectory::must_create(*this));
|
||||
if (ACPI::is_enabled())
|
||||
m_components.append(ACPI::ACPISysFSDirectory::must_create(*this));
|
||||
m_components.append(PowerStateSwitchNode::must_create(*this));
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue