[debugserver] Add --version/-V command line option to debugserver.
authorJonas Devlieghere <jonas@devlieghere.com>
Fri, 27 Sep 2019 21:26:44 +0000 (21:26 +0000)
committerJonas Devlieghere <jonas@devlieghere.com>
Fri, 27 Sep 2019 21:26:44 +0000 (21:26 +0000)
commit0b1b3c6068dfacd267dded0395ef1fa262cb3f8c
tree6c2feb2674761a8fa0665d7556d06f25ebeb9423
parent117512715d66f613b9eb9016725e5c3591f4f9df
[debugserver] Add --version/-V command line option to debugserver.

When not running under a TTY the output is buffered and not flushed
before debugserver exits which makes it impossible to parse the version
string. This adds a -V/--version command that just prints the version to
stdout and exits with an exit code zero.

Differential revision: https://reviews.llvm.org/D68156

llvm-svn: 373127
lldb/tools/debugserver/source/debugserver.cpp