virtcontainers: fix codes misunderstanding in virtcontainers

Still there are some codes left which
will cause some misunderstanding

Change `p` in short of `pod` into `s` or `sandbox`

Fixes: #325

Signed-off-by: Haomin <caihaomin@huawei.com>
This commit is contained in:
c00416947
2018-05-19 15:48:22 +08:00
parent 2245e67f93
commit 7abb8fe326
3 changed files with 69 additions and 69 deletions

View File

@@ -1326,22 +1326,22 @@ func togglePauseSandbox(sandboxID string, pause bool) (*Sandbox, error) {
defer unlockSandbox(lockFile)
// Fetch the sandbox from storage and create it.
p, err := fetchSandbox(sandboxID)
s, err := fetchSandbox(sandboxID)
if err != nil {
return nil, err
}
if pause {
err = p.Pause()
err = s.Pause()
} else {
err = p.Resume()
err = s.Resume()
}
if err != nil {
return nil, err
}
return p, nil
return s, nil
}
// HotplugAddDevice is used for add a device to sandbox