containerd/vendor/github.com/mistifyio/go-zfs/v3/error.go
Sebastiaan van Stijn 05fef52b68
vendor: github.com/containerd/zfs v1.1.0
- update github.com/mistifyio/go-zfs dependency to github.com/mistifyio/go-zfs/v3,
  which contains various bugfixes, and adds go module support (which required a major
  version update): https://github.com/mistifyio/go-zfs/compare/f784269be439...v3.0.1
- remove github.com/pkg/errors dependency
- various minor cleanups/fixes

Full diff: https://github.com/containerd/zfs/compare/v1.0.0...v1.1.0

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2023-07-06 11:56:07 +02:00

19 lines
368 B
Go

package zfs
import (
"fmt"
)
// Error is an error which is returned when the `zfs` or `zpool` shell
// commands return with a non-zero exit code.
type Error struct {
Err error
Debug string
Stderr string
}
// Error returns the string representation of an Error.
func (e Error) Error() string {
return fmt.Sprintf("%s: %q => %s", e.Err, e.Debug, e.Stderr)
}