[all-commits] [llvm/llvm-project] 1fa26e: [PATCH][lldb] Fix dereference of null pointer.

cmtice via All-commits all-commits at lists.llvm.org
Tue Apr 11 13:42:32 PDT 2023


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 1fa26e64fd87c848ff54d08e9a14ea03e01ae645
      https://github.com/llvm/llvm-project/commit/1fa26e64fd87c848ff54d08e9a14ea03e01ae645
  Author: Caroline Tice <cmtice at google.com>
  Date:   2023-04-11 (Tue, 11 Apr 2023)

  Changed paths:
    M lldb/source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp
    A lldb/test/Shell/SymbolFile/DWARF/x86/class-type-nullptr-deref.s

  Log Message:
  -----------
  [PATCH][lldb] Fix dereference of null pointer.

The function DWARFASTParserClang::ParsePointerToMemberType attempts to make
two pointers and then immediately tries to dereference them, without
verifying that the pointesr were successfully created. Sometimes the pointer
creation fails, and the dereference then causes a segfault. This add a check
that the pointers are non-null before attempting to dereference them.




More information about the All-commits mailing list