Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitaly.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPatrick Steinhardt <psteinhardt@gitlab.com>2021-04-21 09:51:29 +0300
committerPatrick Steinhardt <psteinhardt@gitlab.com>2021-04-23 11:42:56 +0300
commit32b2226d515a2099f75ab2f7da062c8c6a09fa29 (patch)
tree68459727a6b3b7b10065c2f279e3287f3cf82bd6 /.golangci.yml
parentd6b658f9a4bf92855c55cd4e2240b79942c13dbe (diff)
golangci: Enable makezero linter
It's a common pitfall to create a slice with a prespecified length and then append to it. If the initial length hasn't been set to zero, then this pattern causes the first `n` entries to be the zero value of its type. The makezero linter finds such patterns. Enable the linter and fix the single violation it surfaces.
Diffstat (limited to '.golangci.yml')
-rw-r--r--.golangci.yml1
1 files changed, 1 insertions, 0 deletions
diff --git a/.golangci.yml b/.golangci.yml
index 8239b4bed..ff8ee1fb7 100644
--- a/.golangci.yml
+++ b/.golangci.yml
@@ -16,6 +16,7 @@ linters:
- gosimple
- govet
- ineffassign
+ - makezero
- megacheck
- misspell
- noctx