[all-commits] [llvm/llvm-project] e387c8: [lldb server] Tidy up LLDB server return codes and...

Sebastian Schwartz via All-commits all-commits at lists.llvm.org
Thu Sep 2 02:17:14 PDT 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: e387c8c413e2127bc93950fb6d786290237b4a9f
      https://github.com/llvm/llvm-project/commit/e387c8c413e2127bc93950fb6d786290237b4a9f
  Author: Sebastian Schwartz <saschwartz at fb.com>
  Date:   2021-09-02 (Thu, 02 Sep 2021)

  Changed paths:
    M lldb/test/Shell/lldb-server/TestErrorMessages.test
    M lldb/test/Shell/lldb-server/TestGdbserverPort.test
    M lldb/tools/lldb-server/lldb-platform.cpp
    M lldb/tools/lldb-server/lldb-server.cpp

  Log Message:
  -----------
  [lldb server] Tidy up LLDB server return codes and associated tests

This diff modifies the LLDB server return codes to more accurately reflect usage
error paths. Specifically we always propagate the return codes from the main
entrypoints into GDB remote LLDB server, and platform LLDB server. This way, the
top-level caller of LLDB server will be able to correctly check whether the
executable exited with or without an error.

We additionally modify and extend the associated shell unit tests to expect
nonzero return codes on error conditions.

Test Plan:
LLDB tests pass:

```
ninja check-lldb
```

Reviewed By: teemperor

Differential Revision: https://reviews.llvm.org/D108351




More information about the All-commits mailing list