[Lldb-commits] [PATCH] D69400: [lldb] [Host/netbsd] Include argv[0] in process_info.GetArguments()

Michał Górny via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Thu Oct 24 10:57:02 PDT 2019


mgorny created this revision.
mgorny added reviewers: krytarowski, labath, wallace.

Include argv[0] in GetArguments(), not only in GetExecutableFile().
This fixes 'process list -v' to report the executable name,
and therefore to pass TestProcessList.


https://reviews.llvm.org/D69400

Files:
  lldb/source/Host/netbsd/Host.cpp


Index: lldb/source/Host/netbsd/Host.cpp
===================================================================
--- lldb/source/Host/netbsd/Host.cpp
+++ lldb/source/Host/netbsd/Host.cpp
@@ -79,6 +79,7 @@
     return false;
 
   Args &proc_args = process_info.GetArguments();
+  proc_args.AppendArgument(llvm::StringRef(cstr));
   while (1) {
     const uint8_t *p = data.PeekData(offset, 1);
     while ((p != NULL) && (*p == '\0') && offset < arg_data_size) {


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D69400.226300.patch
Type: text/x-patch
Size: 457 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/lldb-commits/attachments/20191024/c8adc2da/attachment.bin>


More information about the lldb-commits mailing list