mirror of
https://git.h3cjp.net/H3cJP/yuzu.git
synced 2024-11-14 11:03:19 +00:00
partition_filesystem: Remove dynamic_cast in PrintDebugInfo()
We shouldn't be upcasting our file instances. Given a PartitionFilesystem is currently designed to accept any arbitrary VfsFile instances, casting to a more specific type than that is just bad design, and shows an interface design issue.
This commit is contained in:
parent
458fdda700
commit
57c4d7aa00
|
@ -97,9 +97,8 @@ void PartitionFilesystem::PrintDebugInfo() const {
|
||||||
LOG_DEBUG(Service_FS, "Magic: {:.4}", pfs_header.magic);
|
LOG_DEBUG(Service_FS, "Magic: {:.4}", pfs_header.magic);
|
||||||
LOG_DEBUG(Service_FS, "Files: {}", pfs_header.num_entries);
|
LOG_DEBUG(Service_FS, "Files: {}", pfs_header.num_entries);
|
||||||
for (u32 i = 0; i < pfs_header.num_entries; i++) {
|
for (u32 i = 0; i < pfs_header.num_entries; i++) {
|
||||||
LOG_DEBUG(Service_FS, " > File {}: {} (0x{:X} bytes, at 0x{:X})", i,
|
LOG_DEBUG(Service_FS, " > File {}: {} (0x{:X} bytes)", i,
|
||||||
pfs_files[i]->GetName(), pfs_files[i]->GetSize(),
|
pfs_files[i]->GetName(), pfs_files[i]->GetSize());
|
||||||
dynamic_cast<OffsetVfsFile*>(pfs_files[i].get())->GetOffset());
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue