added pty terminal support to the client side

This commit is contained in:
2025-06-21 02:43:28 +09:00
parent 01eb2edd6e
commit 6baf3b2b53
15 changed files with 748 additions and 35 deletions

View File

@ -109,6 +109,7 @@ type json_out_client_stats struct {
ClientConns int64 `json:"client-conns"`
ClientRoutes int64 `json:"client-routes"`
ClientPeers int64 `json:"client-peers"`
ClientPtsSessions int64 `json:"client-pts-sessions"`
}
// ------------------------------------
@ -1136,6 +1137,7 @@ func (ctl *client_ctl_stats) ServeHTTP(w http.ResponseWriter, req *http.Request)
stats.ClientConns = c.stats.conns.Load()
stats.ClientRoutes = c.stats.routes.Load()
stats.ClientPeers = c.stats.peers.Load()
stats.ClientPtsSessions = c.stats.pts_sessions.Load()
status_code = WriteJsonRespHeader(w, http.StatusOK)
if err = je.Encode(stats); err != nil { goto oops }