Skip to content

Commit 05b0a3c

Browse files
Merge pull request #8271 from adrian-prantl/cherry-pick-stable-20230725-Improve-and-modernize-logging-for-Process-CompleteAttach-82717
[Cherry-pick into stable/20230725] Improve and modernize logging for Process::CompleteAttach() (llvm#82717)
2 parents 6b8518a + c158d64 commit 05b0a3c

File tree

1 file changed

+4
-7
lines changed

1 file changed

+4
-7
lines changed

lldb/source/Target/Process.cpp

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3091,14 +3091,11 @@ void Process::CompleteAttach() {
30913091
DidAttach(process_arch);
30923092

30933093
if (process_arch.IsValid()) {
3094+
LLDB_LOG(log,
3095+
"Process::{0} replacing process architecture with DidAttach() "
3096+
"architecture: \"{1}\"",
3097+
__FUNCTION__, process_arch.GetTriple().getTriple());
30943098
GetTarget().SetArchitecture(process_arch);
3095-
if (log) {
3096-
const char *triple_str = process_arch.GetTriple().getTriple().c_str();
3097-
LLDB_LOGF(log,
3098-
"Process::%s replacing process architecture with DidAttach() "
3099-
"architecture: %s",
3100-
__FUNCTION__, triple_str ? triple_str : "<null>");
3101-
}
31023099
}
31033100

31043101
// We just attached. If we have a platform, ask it for the process

0 commit comments

Comments
 (0)