Skip to content

Commit

Permalink
[lldb] Re-add nullptr check to IRForTarget::RewriteObjCConstString lo…
Browse files Browse the repository at this point in the history
…g statement

The nullptr check here was removed in 4ef50a3
when I replaced (nearly) all log->Print to LLDB_LOG calls (which automatically
check for this stuff). But it seems this one call escaped my sed call.

Currently working on a test that can cover this code path but we can revert
this until I have found one.
  • Loading branch information
Teemperor committed Mar 16, 2020
1 parent 8ff2dcb commit e2d8aa6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lldb/source/Plugins/ExpressionParser/Clang/IRForTarget.cpp
Expand Up @@ -427,7 +427,7 @@ bool IRForTarget::RewriteObjCConstString(llvm::GlobalVariable *ns_str,
m_execution_unit.FindSymbol(g_CFStringCreateWithBytes_str,
missing_weak);
if (CFStringCreateWithBytes_addr == LLDB_INVALID_ADDRESS || missing_weak) {
log->PutCString("Couldn't find CFStringCreateWithBytes in the target");
LLDB_LOG(log, "Couldn't find CFStringCreateWithBytes in the target");

m_error_stream.Printf("Error [IRForTarget]: Rewriting an Objective-C "
"constant string requires "
Expand Down

0 comments on commit e2d8aa6

Please sign in to comment.