1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-23 18:55:08 +00:00

Kernel: Use MUST + Vector::try_append instead of Vector::append

In preparation for making Vector::append unavailable during
compilation of the Kernel.
This commit is contained in:
Brian Gianforcaro 2022-01-03 03:20:39 -08:00 committed by Andreas Kling
parent 8bcce82887
commit 24066ba5ef
5 changed files with 8 additions and 8 deletions

View file

@ -55,14 +55,14 @@ UNMAP_AFTER_INIT void MultiProcessorParser::parse_configuration_table()
entry = (MultiProcessor::EntryHeader*)(FlatPtr)entry + sizeof(MultiProcessor::ProcessorEntry);
break;
case ((u8)MultiProcessor::ConfigurationTableEntryType::Bus):
m_bus_entries.append(*(const MultiProcessor::BusEntry*)entry);
MUST(m_bus_entries.try_append(*(const MultiProcessor::BusEntry*)entry));
entry = (MultiProcessor::EntryHeader*)(FlatPtr)entry + sizeof(MultiProcessor::BusEntry);
break;
case ((u8)MultiProcessor::ConfigurationTableEntryType::IOAPIC):
entry = (MultiProcessor::EntryHeader*)(FlatPtr)entry + sizeof(MultiProcessor::IOAPICEntry);
break;
case ((u8)MultiProcessor::ConfigurationTableEntryType::IO_Interrupt_Assignment):
m_io_interrupt_assignment_entries.append(*(const MultiProcessor::IOInterruptAssignmentEntry*)entry);
MUST(m_io_interrupt_assignment_entries.try_append(*(const MultiProcessor::IOInterruptAssignmentEntry*)entry));
entry = (MultiProcessor::EntryHeader*)(FlatPtr)entry + sizeof(MultiProcessor::IOInterruptAssignmentEntry);
break;
case ((u8)MultiProcessor::ConfigurationTableEntryType::Local_Interrupt_Assignment):