[all-commits] [llvm/llvm-project] 7b3455: [lldb] Fix double free in CommandPluginInterfaceIm...

Jonas Devlieghere via All-commits all-commits at lists.llvm.org
Tue Mar 18 09:48:56 PDT 2025


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 7b3455e24ab5aa090e5b2b9ce50c249843c45754
      https://github.com/llvm/llvm-project/commit/7b3455e24ab5aa090e5b2b9ce50c249843c45754
  Author: Jonas Devlieghere <jonas at devlieghere.com>
  Date:   2025-03-18 (Tue, 18 Mar 2025)

  Changed paths:
    M lldb/source/API/SBCommandInterpreter.cpp
    M lldb/unittests/API/SBCommandInterpreterTest.cpp

  Log Message:
  -----------
  [lldb] Fix double free in CommandPluginInterfaceImplementation (#131658)

The class was taking ownership of the SBCommandPluginInterface pointer
it was passed in, by wrapping it in a shared pointer. This causes a
double free in the unit test when the object is destroyed and the same
pointer gets freed once when the SBCommandPluginInterface goes away and
then again when the shared pointer hits a zero refcount.



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list