(conn ssh.Conn, ticker *time.Ticker, stopCh chan struct{})
| 419 | } |
| 420 | |
| 421 | func keepalive(conn ssh.Conn, ticker *time.Ticker, stopCh chan struct{}) { |
| 422 | for { |
| 423 | select { |
| 424 | case <-ticker.C: |
| 425 | _, _, _ = conn.SendRequest("keepalive@cloudfoundry.org", true, nil) |
| 426 | case <-stopCh: |
| 427 | ticker.Stop() |
| 428 | return |
| 429 | } |
| 430 | } |
| 431 | } |
| 432 | |
| 433 | func (c *secureShell) terminalType() string { |
| 434 | term := os.Getenv("TERM") |
no test coverage detected