runtime: containerd-shim-v2: fix govet fieldalignment

Fix structures alignment

Signed-off-by: Julio Montes <julio.montes@intel.com>
This commit is contained in:
Julio Montes 2021-07-09 12:52:54 -05:00
parent 0dc59df68f
commit 2b80091e14
2 changed files with 30 additions and 23 deletions

View File

@ -24,19 +24,21 @@ type exec struct {
cmds *types.Cmd
tty *tty
ttyio *ttyIO
id string
stdinPipe io.WriteCloser
exitTime time.Time
exitIOch chan struct{}
stdinCloser chan struct{}
exitCh chan uint32
id string
exitCode int32
status task.Status
exitIOch chan struct{}
exitCh chan uint32
stdinCloser chan struct{}
stdinPipe io.WriteCloser
exitTime time.Time
}
type tty struct {

View File

@ -106,15 +106,33 @@ func New(ctx context.Context, id string, publisher cdshim.Publisher, shutdown fu
}
type exit struct {
timestamp time.Time
id string
execid string
pid uint32
status int
timestamp time.Time
}
// service is the shim implementation of a remote shim over GRPC
type service struct {
sandbox vc.VCSandbox
ctx context.Context
rootCtx context.Context // root context for tracing
containers map[string]*container
config *oci.RuntimeConfig
monitor chan error
ec chan exit
events chan interface{}
cancel func()
id string
mu sync.Mutex
eventSendMu sync.Mutex
@ -125,19 +143,6 @@ type service struct {
// shim's pid
pid uint32
ctx context.Context
rootCtx context.Context // root context for tracing
sandbox vc.VCSandbox
containers map[string]*container
config *oci.RuntimeConfig
events chan interface{}
monitor chan error
cancel func()
ec chan exit
id string
}
func newCommand(ctx context.Context, id, containerdBinary, containerdAddress string) (*sysexec.Cmd, error) {