[Lldb-commits] [PATCH] D146263: [lldb] Move UnixSignals creation into Platform plugins

Jordan Rupprecht via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Wed Mar 22 14:41:23 PDT 2023


rupprecht added inline comments.


================
Comment at: lldb/source/Target/UnixSignals.cpp:39
+  // If we have no host platform, be resilient and use default UnixSignals.
+  if (!host_platform_sp)
+    s_unix_signals_sp = std::make_shared<UnixSignals>();
----------------
bulbazord wrote:
> rupprecht wrote:
> > I think the divergence might be happening here -- the host platform is null here, so we get UnixSignals instead of the subcode from LinuxSignals.
> Why might the HostPlatform be nullptr? I assume you're debugging a binary built for some Linux distro on some Linux machine.
Yes, this is a local debugging session of a linux binary running on a linux machine. But it seems from my prodding around that `lldb` calls `Platform::SetHostPlatform()` (via `PlatformLinux::Initialize()`, but `lldb-server` isn't, and `lldb-server` is the thing that supposed to be returning the subcode details.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D146263



More information about the lldb-commits mailing list