From 4255b87aba51778895b77f1d99a731d03eede721 Mon Sep 17 00:00:00 2001 From: bump Date: Mon, 1 Aug 2022 16:04:00 +0000 Subject: [PATCH 1/2] Update github-golangci-lint from 1.47.2 to 1.47.3 Release notes https://github.com/golangci/golangci-lint/releases/tag/v1.47.3 --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 4c9362eb..5cd39b52 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -7,7 +7,7 @@ on: pull_request: env: - GOLANGCILINT_VERSION: 1.47.2 + GOLANGCILINT_VERSION: 1.47.3 jobs: lint: From bc6cffde61d990484cefa6279fbd20fe1a94faec Mon Sep 17 00:00:00 2001 From: Mattias Wadman Date: Mon, 1 Aug 2022 18:47:24 +0200 Subject: [PATCH 2/2] lint,decode,fuzz:: Fix nilerr warnings, one real one should be ignored for now --- format/fuzz_test.go | 2 +- pkg/interp/decode.go | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/format/fuzz_test.go b/format/fuzz_test.go index 837c0b45..f8d90200 100644 --- a/format/fuzz_test.go +++ b/format/fuzz_test.go @@ -82,7 +82,7 @@ func FuzzFormats(f *testing.F) { return nil } if st, err := os.Stat(path); err != nil || st.IsDir() { - return nil + return err } b, readErr := ioutil.ReadFile(path) diff --git a/pkg/interp/decode.go b/pkg/interp/decode.go index 6e7fe45f..5faa8283 100644 --- a/pkg/interp/decode.go +++ b/pkg/interp/decode.go @@ -258,6 +258,7 @@ func (i *Interp) _decode(c any, format string, opts decodeOpts) any { if len(opts.Remain) > 0 { if err := mapstruct.ToStruct(opts.Remain, &inArg); err != nil { // TODO: currently ignores failed struct mappings + //nolint: nilerr return f.DecodeInArg, nil } }