mirror of
https://github.com/containers/podman.git
synced 2025-10-19 20:23:08 +08:00
run modernize -fix ./...
Using golang.org/x/tools/gopls/internal/analysis/modernize/cmd/modernize + some manual cleanup in libpod/lock/shm/shm_lock_test.go as it generated an unused variable + restored one removed comment Signed-off-by: Paul Holzinger <pholzing@redhat.com>
This commit is contained in:
@ -63,10 +63,7 @@ func testInputWithWriteLen(t *testing.T, input []byte, minSparse int64, chunkSiz
|
||||
sparseWriter := NewSparseWriter(m)
|
||||
|
||||
for i := 0; i < len(input); i += chunkSize {
|
||||
end := i + chunkSize
|
||||
if end > len(input) {
|
||||
end = len(input)
|
||||
}
|
||||
end := min(i+chunkSize, len(input))
|
||||
_, err := sparseWriter.Write(input[i:end])
|
||||
if err != nil {
|
||||
t.Fatalf("Expected no error, got %v", err)
|
||||
|
Reference in New Issue
Block a user