Windows: Fix crash in docker system prune
Signed-off-by: John Howard <jhoward@microsoft.com> Upstream-commit: e5900ee9bf0071c6a3ebaf813f82d5345c25d8f0 Component: engine
This commit is contained in:
@ -115,6 +115,8 @@ func readInputEvents(fd uintptr, maxBytes int) ([]winterm.INPUT_RECORD, error) {
|
||||
countRecords := maxBytes / recordSize
|
||||
if countRecords > ansiterm.MAX_INPUT_EVENTS {
|
||||
countRecords = ansiterm.MAX_INPUT_EVENTS
|
||||
} else if countRecords == 0 {
|
||||
countRecords = 1
|
||||
}
|
||||
logger.Debugf("[windows] readInputEvents: Reading %v records (buffer size %v, record size %v)", countRecords, maxBytes, recordSize)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user