mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-06-10 18:10:56 +09:00
Kernel: Fix const-correctness issue in StorageManagement
We have to take the StorageDevice as a mutable reference, otherwise we can't perform any interesting I/O operations on it.
This commit is contained in:
parent
b5cef78e35
commit
0cdd227e9b
Notes:
sideshowbarker
2024-07-17 10:05:47 +09:00
Author: https://github.com/awesomekling
Commit: 0cdd227e9b
Pull-request: https://github.com/SerenityOS/serenity/pull/17557
Reviewed-by: https://github.com/linusg
2 changed files with 2 additions and 2 deletions
|
@ -156,7 +156,7 @@ UNMAP_AFTER_INIT void StorageManagement::dump_storage_devices_and_partitions() c
|
|||
}
|
||||
}
|
||||
|
||||
UNMAP_AFTER_INIT ErrorOr<NonnullOwnPtr<Partition::PartitionTable>> StorageManagement::try_to_initialize_partition_table(StorageDevice const& device) const
|
||||
UNMAP_AFTER_INIT ErrorOr<NonnullOwnPtr<Partition::PartitionTable>> StorageManagement::try_to_initialize_partition_table(StorageDevice& device) const
|
||||
{
|
||||
auto mbr_table_or_error = Partition::MBRPartitionTable::try_to_initialize(device);
|
||||
if (!mbr_table_or_error.is_error())
|
||||
|
|
|
@ -61,7 +61,7 @@ private:
|
|||
|
||||
void dump_storage_devices_and_partitions() const;
|
||||
|
||||
ErrorOr<NonnullOwnPtr<Partition::PartitionTable>> try_to_initialize_partition_table(StorageDevice const&) const;
|
||||
ErrorOr<NonnullOwnPtr<Partition::PartitionTable>> try_to_initialize_partition_table(StorageDevice&) const;
|
||||
|
||||
LockRefPtr<BlockDevice> boot_block_device() const;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue