mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-09-20 00:08:55 +00:00
Kernel: Stop using the make<T> factory method in the Kernel
As make<T> is infallible, it really should not be used anywhere in the Kernel. Instead replace with fallible `new (nothrow)` calls, that will eventually be error-propagated.
This commit is contained in:
parent
e5e7cb822a
commit
8289727fac
Notes:
sideshowbarker
2024-07-17 19:49:48 +09:00
Author: https://github.com/IdanHo
Commit: 8289727fac
Pull-request: https://github.com/SerenityOS/serenity/pull/12275
6 changed files with 7 additions and 7 deletions
|
@ -367,7 +367,7 @@ UNMAP_AFTER_INIT void APIC::setup_ap_boot_environment()
|
|||
// Allocate Processor structures for all APs and store the pointer to the data
|
||||
m_ap_processor_info.resize(aps_to_enable);
|
||||
for (size_t i = 0; i < aps_to_enable; i++)
|
||||
m_ap_processor_info[i] = make<Processor>();
|
||||
m_ap_processor_info[i] = adopt_nonnull_own_or_enomem(new (nothrow) Processor()).release_value_but_fixme_should_propagate_errors();
|
||||
auto* ap_processor_info_array = &ap_stack_array[aps_to_enable];
|
||||
for (size_t i = 0; i < aps_to_enable; i++) {
|
||||
ap_processor_info_array[i] = FlatPtr(m_ap_processor_info[i].ptr());
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue