Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit1357a3a

Browse files
authored
chore: improve logging and x11 handler call (#18422)
* use `ctx` instead of `session.Context()` for consistency* log SSH connection start with the phrase `ssh connection` for symmetrywith the stop log and ease of `grep`'ing.
1 parent8f6a5af commit1357a3a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

‎agent/agentssh/agentssh.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -454,7 +454,7 @@ func (s *Server) sessionHandler(session ssh.Session) {
454454

455455
x11,hasX11:=session.X11()
456456
ifhasX11 {
457-
display,handled:=s.x11Handler(session.Context(),x11)
457+
display,handled:=s.x11Handler(ctx,x11)
458458
if!handled {
459459
logger.Error(ctx,"x11 handler failed")
460460
closeCause("x11 handler failed")
@@ -973,7 +973,7 @@ func (s *Server) handleConn(l net.Listener, c net.Conn) {
973973
return
974974
}
975975
defers.trackConn(l,c,false)
976-
logger.Info(context.Background(),"started serving connection")
976+
logger.Info(context.Background(),"started servingsshconnection")
977977
// note: srv.ConnectionCompleteCallback logs completion of the connection
978978
s.srv.HandleConn(c)
979979
}

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp