renamed pts to pty to avoid name collision

This commit is contained in:
2025-08-08 19:24:52 +09:00
parent 3fd91b2c45
commit d0f1663bf3
15 changed files with 470 additions and 298 deletions

View File

@ -76,7 +76,7 @@ type json_out_server_stats struct {
ServerPeers int64 `json:"server-peers"`
SshProxySessions int64 `json:"pxy-ssh-sessions"`
ServerPtsSessions int64 `json:"server-pts-sessions"`
ServerPtySessions int64 `json:"server-pty-sessions"`
}
// this is a more specialized variant of json_in_notice
@ -920,7 +920,7 @@ func (ctl *server_ctl_stats) ServeHTTP(w http.ResponseWriter, req *http.Request)
stats.ServerRoutes = s.stats.routes.Load()
stats.ServerPeers = s.stats.peers.Load()
stats.SshProxySessions = s.stats.ssh_proxy_sessions.Load()
stats.ServerPtsSessions = s.stats.pts_sessions.Load()
stats.ServerPtySessions = s.stats.pty_sessions.Load()
status_code = WriteJsonRespHeader(w, http.StatusOK)
if err = je.Encode(stats); err != nil { goto oops }