[all-commits] [llvm/llvm-project] fd37d4: Set error message if ValueObjectRegister fails to ...
Ilya Nozhkin via All-commits
all-commits at lists.llvm.org
Sun Feb 27 22:31:06 PST 2022
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: fd37d489cfef3bf7d06b2b43dac2ad1381cdc56b
https://github.com/llvm/llvm-project/commit/fd37d489cfef3bf7d06b2b43dac2ad1381cdc56b
Author: Ilya Nozhkin <nozhkin.ii at gmail.com>
Date: 2022-02-28 (Mon, 28 Feb 2022)
Changed paths:
M lldb/source/Core/ValueObjectRegister.cpp
M lldb/test/API/functionalities/postmortem/elf-core/TestLinuxCore.py
Log Message:
-----------
Set error message if ValueObjectRegister fails to write back to register
SetValueFromCString and SetData methods return false if register can't
be written but they don't set a error message. It sometimes confuses
callers of these methods because they try to get the error message in case of
failure but Status::AsCString returns nullptr.
For example, lldb-vscode crashes due to this bug if some register can't
be written. It invokes SBError::GetCString in case of error and doesn't
check whether the result is nullptr (see request_setVariable implementation in
lldb-vscode.cpp for more info).
Reviewed By: labath, clayborg
Differential Revision: https://reviews.llvm.org/D120319
More information about the All-commits
mailing list