diff options
Diffstat (limited to 'lib/DebugInfo/DWARF/DWARFGdbIndex.cpp')
-rw-r--r-- | lib/DebugInfo/DWARF/DWARFGdbIndex.cpp | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/lib/DebugInfo/DWARF/DWARFGdbIndex.cpp b/lib/DebugInfo/DWARF/DWARFGdbIndex.cpp index 1abd931e3b8b..f5f975578082 100644 --- a/lib/DebugInfo/DWARF/DWARFGdbIndex.cpp +++ b/lib/DebugInfo/DWARF/DWARFGdbIndex.cpp @@ -1,9 +1,8 @@ //===- DWARFGdbIndex.cpp --------------------------------------------------===// // -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // //===----------------------------------------------------------------------===// @@ -121,7 +120,7 @@ bool DWARFGdbIndex::parseImpl(DataExtractor Data) { return false; CuListOffset = Data.getU32(&Offset); - uint32_t CuTypesOffset = Data.getU32(&Offset); + TuListOffset = Data.getU32(&Offset); AddressAreaOffset = Data.getU32(&Offset); SymbolTableOffset = Data.getU32(&Offset); ConstantPoolOffset = Data.getU32(&Offset); @@ -129,7 +128,7 @@ bool DWARFGdbIndex::parseImpl(DataExtractor Data) { if (Offset != CuListOffset) return false; - uint32_t CuListSize = (CuTypesOffset - CuListOffset) / 16; + uint32_t CuListSize = (TuListOffset - CuListOffset) / 16; CuList.reserve(CuListSize); for (uint32_t i = 0; i < CuListSize; ++i) { uint64_t CuOffset = Data.getU64(&Offset); @@ -139,7 +138,7 @@ bool DWARFGdbIndex::parseImpl(DataExtractor Data) { // CU Types are no longer needed as DWARF skeleton type units never made it // into the standard. - uint32_t TuListSize = (AddressAreaOffset - CuTypesOffset) / 24; + uint32_t TuListSize = (AddressAreaOffset - TuListOffset) / 24; TuList.resize(TuListSize); for (uint32_t I = 0; I < TuListSize; ++I) { uint64_t CuOffset = Data.getU64(&Offset); |