diff options
| author | Daniel J Walsh <dwalsh@redhat.com> | 2021-11-19 14:25:58 -0500 |
|---|---|---|
| committer | Daniel J Walsh <dwalsh@redhat.com> | 2021-11-19 14:26:03 -0500 |
| commit | 44b240470270021e2680afe9de62e5096067a1bf (patch) | |
| tree | eae48e206f340a2695b1f54582fb3b28fc7cad2d /vendor/github.com/rootless-containers/rootlesskit/pkg/msgutil | |
| parent | 2755d0255c94ac2ef797636935f83e3351d4d5af (diff) | |
| download | podman-44b240470270021e2680afe9de62e5096067a1bf.tar.gz podman-44b240470270021e2680afe9de62e5096067a1bf.tar.bz2 podman-44b240470270021e2680afe9de62e5096067a1bf.zip | |
Bump github.com/rootless-containers/rootlesskit from 0.14.5 to 0.14.6
Bumps [github.com/rootless-containers/rootlesskit](https://github.com/rootless-containers/rootlesskit) from 0.14.5 to 0.14.6.
- [Release notes](https://github.com/rootless-containers/rootlesskit/releases)
- [Commits](rootless-containers/rootlesskit@v0.14.5...v0.14.6)
---
updated-dependencies:
- dependency-name: github.com/rootless-containers/rootlesskit
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
Diffstat (limited to 'vendor/github.com/rootless-containers/rootlesskit/pkg/msgutil')
| -rw-r--r-- | vendor/github.com/rootless-containers/rootlesskit/pkg/msgutil/msgutil.go | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/vendor/github.com/rootless-containers/rootlesskit/pkg/msgutil/msgutil.go b/vendor/github.com/rootless-containers/rootlesskit/pkg/msgutil/msgutil.go index a0a0c94c6..74caa9a49 100644 --- a/vendor/github.com/rootless-containers/rootlesskit/pkg/msgutil/msgutil.go +++ b/vendor/github.com/rootless-containers/rootlesskit/pkg/msgutil/msgutil.go @@ -5,9 +5,8 @@ import ( "bytes" "encoding/binary" "encoding/json" + "fmt" "io" - - "github.com/pkg/errors" ) const ( @@ -20,7 +19,7 @@ func MarshalToWriter(w io.Writer, x interface{}) (int, error) { return 0, err } if len(b) > maxLength { - return 0, errors.Errorf("bad message length: %d (max: %d)", len(b), maxLength) + return 0, fmt.Errorf("bad message length: %d (max: %d)", len(b), maxLength) } h := make([]byte, 4) binary.LittleEndian.PutUint32(h, uint32(len(b))) @@ -34,11 +33,11 @@ func UnmarshalFromReader(r io.Reader, x interface{}) (int, error) { return n, err } if n != 4 { - return n, errors.Errorf("read %d bytes, expected 4 bytes", n) + return n, fmt.Errorf("read %d bytes, expected 4 bytes", n) } bLen := binary.LittleEndian.Uint32(hdr) if bLen > maxLength || bLen < 1 { - return n, errors.Errorf("bad message length: %d (max: %d)", bLen, maxLength) + return n, fmt.Errorf("bad message length: %d (max: %d)", bLen, maxLength) } b := make([]byte, bLen) n, err = r.Read(b) @@ -46,7 +45,7 @@ func UnmarshalFromReader(r io.Reader, x interface{}) (int, error) { return 4 + n, err } if n != int(bLen) { - return 4 + n, errors.Errorf("read %d bytes, expected %d bytes", n, bLen) + return 4 + n, fmt.Errorf("read %d bytes, expected %d bytes", n, bLen) } return 4 + n, json.Unmarshal(b, x) } @@ -60,7 +59,7 @@ func Marshal(x interface{}) ([]byte, error) { func Unmarshal(b []byte, x interface{}) error { n, err := UnmarshalFromReader(bytes.NewReader(b), x) if n != len(b) { - return errors.Errorf("read %d bytes, expected %d bytes", n, len(b)) + return fmt.Errorf("read %d bytes, expected %d bytes", n, len(b)) } return err } |
