MCPcopy Index your code
hub / github.com/docker/cli / CloseRead

Method CloseRead

cli/connhelper/commandconn/commandconn.go:197–209  ·  view source on GitHub ↗

CloseRead allows commandConn to implement halfCloser

()

Source from the content-addressed store, hash-verified

195
196// CloseRead allows commandConn to implement halfCloser
197func (c *commandConn) CloseRead() error {
198 // NOTE: maybe already closed here
199 if err := c.stdout.Close(); err != nil && !ignorableCloseError(err) {
200 return err
201 }
202 c.stdoutClosed.Store(true)
203
204 if c.stdinClosed.Load() {
205 c.kill()
206 }
207
208 return nil
209}
210
211// CloseWrite allows commandConn to implement halfCloser
212func (c *commandConn) CloseWrite() error {

Callers 1

CloseMethod · 0.95

Calls 4

killMethod · 0.95
ignorableCloseErrorFunction · 0.85
StoreMethod · 0.65
CloseMethod · 0.45

Tested by

no test coverage detected