Skip to content

Commit bb792ed

Browse files
author
Mrunal Patel
authored
Merge pull request #1058 from datawolf/update-pause-comment
update the comment for container.Pause() method on linux
2 parents 20c7c3b + 59a241f commit bb792ed

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

libcontainer/container_linux.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -85,14 +85,14 @@ type Container interface {
8585
// Systemerror - System error.
8686
Restore(process *Process, criuOpts *CriuOpts) error
8787

88-
// If the Container state is RUNNING, sets the Container state to PAUSING and pauses
88+
// If the Container state is RUNNING or CREATED, sets the Container state to PAUSING and pauses
8989
// the execution of any user processes. Asynchronously, when the container finished being paused the
9090
// state is changed to PAUSED.
9191
// If the Container state is PAUSED, do nothing.
9292
//
9393
// errors:
9494
// ContainerNotExists - Container no longer exists,
95-
// ContainerNotRunning - Container not running,
95+
// ContainerNotRunning - Container not running or created,
9696
// Systemerror - System error.
9797
Pause() error
9898

@@ -445,7 +445,7 @@ func (c *linuxContainer) Pause() error {
445445
c: c,
446446
})
447447
}
448-
return newGenericError(fmt.Errorf("container not running: %s", status), ContainerNotRunning)
448+
return newGenericError(fmt.Errorf("container not running or created: %s", status), ContainerNotRunning)
449449
}
450450

451451
func (c *linuxContainer) Resume() error {

0 commit comments

Comments
 (0)