Skip to content

[lldb-dap] Minor change to stdio client name. #141266

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
May 23, 2025
Merged

Conversation

ashgti
Copy link
Contributor

@ashgti ashgti commented May 23, 2025

Update the stdin <-> stdout client name to stdio. I noticed on macOS if I get a crash report from lldb-dap the / in the client name causes some thread names to be reported without the full name. For example Thread 6 Crashed:: */stdout.event_handler. Switching to stdio I think is still clear and not truncated in the macOS crash reports.

Update the stdin <-> stdout client name to `stdio`. I noticed on macOS if I get a crash report from lldb-dap the `/` in the client name causes some thread names to be reported without the full name. For example `Thread 6 Crashed:: */stdout.event_handler`. Switching to `stdio` I think is still clear and not truncated in the macOS crash reports.
@llvmbot
Copy link
Member

llvmbot commented May 23, 2025

@llvm/pr-subscribers-lldb

Author: John Harrison (ashgti)

Changes

Update the stdin <-> stdout client name to stdio. I noticed on macOS if I get a crash report from lldb-dap the / in the client name causes some thread names to be reported without the full name. For example Thread 6 Crashed:: */stdout.event_handler. Switching to stdio I think is still clear and not truncated in the macOS crash reports.


Full diff: https://github.com/llvm/llvm-project/pull/141266.diff

1 Files Affected:

  • (modified) lldb/tools/lldb-dap/tool/lldb-dap.cpp (+1-1)
diff --git a/lldb/tools/lldb-dap/tool/lldb-dap.cpp b/lldb/tools/lldb-dap/tool/lldb-dap.cpp
index 7a4cc70902a56..9b9de5e21a742 100644
--- a/lldb/tools/lldb-dap/tool/lldb-dap.cpp
+++ b/lldb/tools/lldb-dap/tool/lldb-dap.cpp
@@ -542,7 +542,7 @@ int main(int argc, char *argv[]) {
   lldb::IOObjectSP output = std::make_shared<NativeFile>(
       stdout_fd, File::eOpenOptionWriteOnly, NativeFile::Unowned);
 
-  constexpr llvm::StringLiteral client_name = "stdin/stdout";
+  constexpr llvm::StringLiteral client_name = "stdio";
   Transport transport(client_name, log.get(), input, output);
   DAP dap(log.get(), default_repl_mode, pre_init_commands, transport);
 

@ashgti ashgti merged commit b2bb0f9 into llvm:main May 23, 2025
12 of 13 checks passed
@ashgti ashgti deleted the lldb-dap-name branch May 23, 2025 18:09
sivan-shani pushed a commit to sivan-shani/llvm-project that referenced this pull request Jun 3, 2025
Update the stdin <-> stdout client name to `stdio`. I noticed on macOS
if I get a crash report from lldb-dap the `/` in the client name causes
some thread names to be reported without the full name. For example
`Thread 6 Crashed:: */stdout.event_handler`. Switching to `stdio` I
think is still clear and not truncated in the macOS crash reports.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants