[Lldb-commits] [PATCH] D108018: [lldb] [gdb-remote] Support QEnvironment fallback to hex-encoded

Michał Górny via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Tue Sep 7 09:43:20 PDT 2021


mgorny added inline comments.


================
Comment at: lldb/test/API/tools/lldb-server/main.cpp:332
+      const char *value = getenv(arg.c_str());
+      printf("%s\n", value ? value : "__unset__");
     } else {
----------------
labath wrote:
> Printing a quoted this in the case of a null pointer is exactly the opposite of what one would normally expect. It's not a big deal, since we control the inputs, but it may still be better to print `<unset>` or something like that instead...
i.e. `s/__unset__/<unset>/`? I have strong Python background, and double underscores are common for special stuff in Python world.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D108018/new/

https://reviews.llvm.org/D108018



More information about the lldb-commits mailing list