Skip to content

Commit

Permalink
[LLDB][NFC][Correctness] Fix bad null check
Browse files Browse the repository at this point in the history
Fix incorrect null-check logic, likely cause by copy-paste

Differential Revision: https://reviews.llvm.org/D130937
  • Loading branch information
fixathon committed Aug 1, 2022
1 parent dd29b3c commit 30b3911
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lldb/source/Plugins/Process/POSIX/NativeProcessELF.cpp
Expand Up @@ -161,7 +161,7 @@ NativeProcessELF::GetLoadedSVR4Libraries() {
GetAddressByteSize(), bytes_read);
if (!status.Success())
return status.ToError();
if (address == 0)
if (link_map == 0)
return llvm::createStringError(llvm::inconvertibleErrorCode(),
"Invalid link_map address");

Expand Down

0 comments on commit 30b3911

Please sign in to comment.