Close attach control file

From CRI-O #1288

Signed-off-by: Matthew Heon <mheon@redhat.com>

Closes: #263
Approved by: umohnani8
This commit is contained in:
Matthew Heon
2018-01-26 03:08:41 -05:00
committed by Atomic Bot
parent e47fcdf170
commit 36e6009f00

View File

@ -61,6 +61,7 @@ func (c *Container) attachContainerSocket(resize <-chan remotecommand.TerminalSi
if err != nil {
return errors.Wrapf(err, "failed to open container ctl file: %v")
}
defer controlFile.Close()
kubecontainer.HandleResizing(resize, func(size remotecommand.TerminalSize) {
logrus.Debugf("Received a resize event: %+v", size)