diff --git a/Userland/Libraries/LibDebug/Dwarf/DwarfInfo.cpp b/Userland/Libraries/LibDebug/Dwarf/DwarfInfo.cpp index eecfa2d0b3..485a2e6151 100644 --- a/Userland/Libraries/LibDebug/Dwarf/DwarfInfo.cpp +++ b/Userland/Libraries/LibDebug/Dwarf/DwarfInfo.cpp @@ -53,7 +53,7 @@ ErrorOr DwarfInfo::populate_compilation_units() while (!debug_info_stream->is_eof()) { auto unit_offset = TRY(debug_info_stream->tell()); - auto compilation_unit_header = TRY(CompilationUnitHeader::read_from_stream(*debug_info_stream)); + auto compilation_unit_header = TRY(debug_info_stream->read_value()); VERIFY(compilation_unit_header.common.version <= 5); VERIFY(compilation_unit_header.address_size() == sizeof(FlatPtr)); diff --git a/Userland/Libraries/LibDebug/Dwarf/LineProgram.cpp b/Userland/Libraries/LibDebug/Dwarf/LineProgram.cpp index 12d0fa4c5d..0b23eccb48 100644 --- a/Userland/Libraries/LibDebug/Dwarf/LineProgram.cpp +++ b/Userland/Libraries/LibDebug/Dwarf/LineProgram.cpp @@ -27,7 +27,7 @@ LineProgram::LineProgram(DwarfInfo& dwarf_info, Core::Stream::SeekableStream& st ErrorOr LineProgram::parse_unit_header() { - m_unit_header = TRY(LineProgramUnitHeader32::read_from_stream(m_stream)); + m_unit_header = TRY(m_stream.read_value()); VERIFY(m_unit_header.version() >= MIN_DWARF_VERSION && m_unit_header.version() <= MAX_DWARF_VERSION); VERIFY(m_unit_header.opcode_base() <= sizeof(m_unit_header.std_opcode_lengths) / sizeof(m_unit_header.std_opcode_lengths[0]) + 1);