[all-commits] [llvm/llvm-project] b761a6: [DWARF] Detect extraction errors in DWARFFormValue...

Pavel Labath via All-commits all-commits at lists.llvm.org
Thu Apr 9 04:43:59 PDT 2020


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: b761a6484d4035785565d41db540bfa7b5fd677d
      https://github.com/llvm/llvm-project/commit/b761a6484d4035785565d41db540bfa7b5fd677d
  Author: Pavel Labath <pavel at labath.sk>
  Date:   2020-04-09 (Thu, 09 Apr 2020)

  Changed paths:
    M llvm/lib/DebugInfo/DWARF/DWARFFormValue.cpp
    M llvm/unittests/DebugInfo/DWARF/DWARFFormValueTest.cpp

  Log Message:
  -----------
  [DWARF] Detect extraction errors in DWARFFormValue::extractValue

Summary:
Although the function had a bool return value, it was always returning
true. Presumably this is because the main type of errors one can
encounter here is running off the end of the stream, and until very
recently, the DataExtractor class made it very difficult to detect that.

The situation has changed now, and we can easily detect errors here,
which this patch does.

Reviewers: dblaikie, aprantl

Subscribers: hiraditya, llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D77308




More information about the All-commits mailing list