Browse code

oci: fix SA4009: argument e is overwritten before first use (staticcheck)

```
oci/devices_linux.go:64:72: SA4009: argument e is overwritten before first use (staticcheck)
```

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>

Sebastiaan van Stijn authored on 2019/08/29 02:29:19
Showing 1 changed files
... ...
@@ -61,7 +61,8 @@ func DevicesFromPath(pathOnHost, pathInContainer, cgroupPermissions string) (dev
61 61
 		if src, e := os.Stat(resolvedPathOnHost); e == nil && src.IsDir() {
62 62
 
63 63
 			// mount the internal devices recursively
64
-			filepath.Walk(resolvedPathOnHost, func(dpath string, f os.FileInfo, e error) error {
64
+			// TODO check if additional errors should be handled or logged
65
+			_ = filepath.Walk(resolvedPathOnHost, func(dpath string, f os.FileInfo, _ error) error {
65 66
 				childDevice, e := devices.DeviceFromPath(dpath, cgroupPermissions)
66 67
 				if e != nil {
67 68
 					// ignore the device