mirror of
https://github.com/minio/minio.git
synced 2025-11-08 21:24:55 -05:00
fix: reduce using memory and temporary files. (#17206)
This commit is contained in:
@@ -42,13 +42,33 @@ func (e BadDigest) Error() string {
|
||||
return "Bad digest: Expected " + e.ExpectedMD5 + " does not match calculated " + e.CalculatedMD5
|
||||
}
|
||||
|
||||
// ErrSizeMismatch error size mismatch
|
||||
type ErrSizeMismatch struct {
|
||||
// SizeTooSmall reader size too small
|
||||
type SizeTooSmall struct {
|
||||
Want int64
|
||||
Got int64
|
||||
}
|
||||
|
||||
func (e ErrSizeMismatch) Error() string {
|
||||
func (e SizeTooSmall) Error() string {
|
||||
return fmt.Sprintf("Size small: got %d, want %d", e.Got, e.Want)
|
||||
}
|
||||
|
||||
// SizeTooLarge reader size too large
|
||||
type SizeTooLarge struct {
|
||||
Want int64
|
||||
Got int64
|
||||
}
|
||||
|
||||
func (e SizeTooLarge) Error() string {
|
||||
return fmt.Sprintf("Size large: got %d, want %d", e.Got, e.Want)
|
||||
}
|
||||
|
||||
// SizeMismatch error size mismatch
|
||||
type SizeMismatch struct {
|
||||
Want int64
|
||||
Got int64
|
||||
}
|
||||
|
||||
func (e SizeMismatch) Error() string {
|
||||
return fmt.Sprintf("Size mismatch: got %d, want %d", e.Got, e.Want)
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user