mirror of
https://github.com/moby/moby.git
synced 2022-11-09 12:21:53 -05:00
Fix bug in engine.Sender
Docker-DCO-1.1-Signed-off-by: Solomon Hykes <solomon@docker.com> (github: shykes)
This commit is contained in:
parent
62f4c88443
commit
9236e088eb
1 changed files with 2 additions and 2 deletions
|
@ -55,10 +55,10 @@ func (s *Sender) Handle(job *Job) Status {
|
|||
var status int
|
||||
r.NewRoute().KeyStartsWith("cmd", "status").Handler(func(p []byte, f *os.File) error {
|
||||
cmd := data.Message(p).Get("cmd")
|
||||
if len(cmd) != 3 {
|
||||
if len(cmd) != 2 {
|
||||
return fmt.Errorf("usage: %s <0-127>", cmd[0])
|
||||
}
|
||||
s, err := strconv.ParseUint(cmd[2], 10, 8)
|
||||
s, err := strconv.ParseUint(cmd[1], 10, 8)
|
||||
if err != nil {
|
||||
return fmt.Errorf("usage: %s <0-127>", cmd[0])
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue