-
Notifications
You must be signed in to change notification settings - Fork 259
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
When querying the stats of a container that is in the process of being stopped, an ERROR_INVALID_HANDLE (0x6) may be returned. This change ignores that error and returns an empty stats object. This change also fixes the return values of Stats() when encountering one of the expected errors. Returning nil stats when error is nil will break caller assumptions of finding a valid value when error is nil. Instead, an ErrNotFound is returned. Signed-off-by: Gabriel Adrian Samfira <[email protected]> (cherry picked from commit 790bcae) Signed-off-by: Daniel Canter <[email protected]>
- Loading branch information
Showing
4 changed files
with
31 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
12 changes: 12 additions & 0 deletions
12
test/vendor/github.com/Microsoft/hcsshim/internal/hcs/errors.go
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.