Skip to content

Commit c6a4593

Browse files
committed
fix comment
1 parent 1a6b428 commit c6a4593

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

agent/agentscripts/agentscripts.go

+7-1
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,13 @@ import (
2727
var (
2828
// ErrTimeout is returned when a script times out.
2929
ErrTimeout = xerrors.New("script timed out")
30-
// ErrTimeout is returned when a script times out.
30+
// ErrOutputPipesOpen is returned when a script exits leaving the output
31+
// pipe(s) (stdout, stderr) open. This happens because we set WaitDelay on
32+
// the command, which gives us two things:
33+
//
34+
// 1. The ability to ensure that a script exits (this is important for e.g.
35+
// blocking login, and avoiding doing so indefinitely)
36+
// 2. Improved command cancellation on timeout
3137
ErrOutputPipesOpen = xerrors.New("script exited without closing output pipes")
3238

3339
parser = cron.NewParser(cron.Second | cron.Minute | cron.Hour | cron.Dom | cron.Month | cron.DowOptional)

0 commit comments

Comments
 (0)