summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorRich Trott <rtrott@gmail.com>2021-07-09 18:19:41 -0700
committerMichaël Zasso <targos@protonmail.com>2021-09-04 15:14:25 +0200
commit49e0883c75e335520a2fcb6d5cc3071b5179c1dd (patch)
tree47471f1ac054146e9e643a44ae30c5d0c46deb36 /src
parentedc5791b5a8346d108e5592d67faf6b24244bf97 (diff)
downloadnode-new-49e0883c75e335520a2fcb6d5cc3071b5179c1dd.tar.gz
debugger: indicate server is ending
Currently, we say "listening" when we are ending the server. Change it to "ending". Fixes: https://github.com/nodejs/node/issues/39272 PR-URL: https://github.com/nodejs/node/pull/39334 Reviewed-By: Michaël Zasso <targos@protonmail.com> Reviewed-By: Yash Ladha <yash@yashladha.in>
Diffstat (limited to 'src')
-rw-r--r--src/inspector_socket_server.cc6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/inspector_socket_server.cc b/src/inspector_socket_server.cc
index 29e0c12802..299664da9a 100644
--- a/src/inspector_socket_server.cc
+++ b/src/inspector_socket_server.cc
@@ -234,6 +234,7 @@ void PrintDebuggerReadyMessage(
const std::string& host,
const std::vector<InspectorSocketServer::ServerSocketPtr>& server_sockets,
const std::vector<std::string>& ids,
+ const char* verb,
bool publish_uid_stderr,
FILE* out) {
if (!publish_uid_stderr || out == nullptr) {
@@ -241,7 +242,8 @@ void PrintDebuggerReadyMessage(
}
for (const auto& server_socket : server_sockets) {
for (const std::string& id : ids) {
- fprintf(out, "Debugger listening on %s\n",
+ fprintf(out, "Debugger %s on %s\n",
+ verb,
FormatWsAddress(host, server_socket->port(), id, true).c_str());
}
}
@@ -300,6 +302,7 @@ void InspectorSocketServer::SessionTerminated(int session_id) {
PrintDebuggerReadyMessage(host_,
server_sockets_,
delegate_->GetTargetIds(),
+ "ending",
inspect_publish_uid_.console,
out_);
}
@@ -425,6 +428,7 @@ bool InspectorSocketServer::Start() {
PrintDebuggerReadyMessage(host_,
server_sockets_,
delegate_->GetTargetIds(),
+ "listening",
inspect_publish_uid_.console,
out_);
return true;