Skip to content

Commit 2d955cb

Browse files
thaJeztahcorhere
authored andcommitted
linting: assigned to src, but reassigned without using the value (wastedassign)
cli/command/container/opts.go:928:2: assigned to src, but reassigned without using the value (wastedassign) src := "" ^ Signed-off-by: Sebastiaan van Stijn <[email protected]> (cherry picked from commit 3dfdaa6) Signed-off-by: Cory Snider <[email protected]>
1 parent b8dd4ca commit 2d955cb

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

cli/command/container/opts.go

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -911,8 +911,7 @@ func parseDevice(device, serverOS string) (container.DeviceMapping, error) {
911911
// parseLinuxDevice parses a device mapping string to a container.DeviceMapping struct
912912
// knowing that the target is a Linux daemon
913913
func parseLinuxDevice(device string) (container.DeviceMapping, error) {
914-
src := ""
915-
dst := ""
914+
var src, dst string
916915
permissions := "rwm"
917916
arr := strings.Split(device, ":")
918917
switch len(arr) {

0 commit comments

Comments
 (0)