summaryrefslogtreecommitdiff
path: root/libcontainerd
diff options
context:
space:
mode:
authorSebastiaan van Stijn <github@gone.nl>2022-07-13 22:30:47 +0200
committerSebastiaan van Stijn <github@gone.nl>2022-07-13 22:31:53 +0200
commit4f0834668696c981ef56ee77dc7af05bf3d0dbf9 (patch)
treef701e0711c6da643ddd40e1d572cba1d82be40b1 /libcontainerd
parentdc4ab45e05d0b42deccfefddcaf17fdcb75e497c (diff)
downloaddocker-4f0834668696c981ef56ee77dc7af05bf3d0dbf9.tar.gz
fix formatting of "nolint" tags for go1.19
The correct formatting for machine-readable comments is; //<some alphanumeric identifier>:<options>[,<option>...][ // comment] Which basically means: - MUST NOT have a space before `<identifier>` (e.g. `nolint`) - Identified MUST be alphanumeric - MUST be followed by a colon - MUST be followed by at least one `<option>` - Optionally additional `<options>` (comma-separated) - Optionally followed by a comment Any other format will not be considered a machine-readable comment by `gofmt`, and thus formatted as a regular comment. Note that this also means that a `//nolint` (without anything after it) is considered invalid, same for `//#nosec` (starts with a `#`). Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Diffstat (limited to 'libcontainerd')
-rw-r--r--libcontainerd/remote/client.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/libcontainerd/remote/client.go b/libcontainerd/remote/client.go
index 552d7d11f1..a2b895b328 100644
--- a/libcontainerd/remote/client.go
+++ b/libcontainerd/remote/client.go
@@ -558,7 +558,7 @@ func (c *client) CreateCheckpoint(ctx context.Context, containerID, checkpointDi
for _, m := range index.Manifests {
m := m
if m.MediaType == images.MediaTypeContainerd1Checkpoint {
- cpDesc = &m // nolint:gosec
+ cpDesc = &m //nolint:gosec
break
}
}