summaryrefslogtreecommitdiff
path: root/test/testvol
diff options
context:
space:
mode:
authorPaul Holzinger <pholzing@redhat.com>2022-04-22 15:10:13 +0200
committerPaul Holzinger <pholzing@redhat.com>2022-04-25 13:23:20 +0200
commitc7b16645aff27fff0b87bb2a98298693bbf20894 (patch)
treed93f86c9e13f0f87f09eb048929add31e13f8f93 /test/testvol
parentad3da638ce17439a7adbf2aa7e1b4017d583f660 (diff)
downloadpodman-c7b16645aff27fff0b87bb2a98298693bbf20894.tar.gz
podman-c7b16645aff27fff0b87bb2a98298693bbf20894.tar.bz2
podman-c7b16645aff27fff0b87bb2a98298693bbf20894.zip
enable unparam linter
The unparam linter is useful to detect unused function parameters and return values. Signed-off-by: Paul Holzinger <pholzing@redhat.com>
Diffstat (limited to 'test/testvol')
-rw-r--r--test/testvol/main.go9
1 files changed, 3 insertions, 6 deletions
diff --git a/test/testvol/main.go b/test/testvol/main.go
index d15bf00cd..00b462eb2 100644
--- a/test/testvol/main.go
+++ b/test/testvol/main.go
@@ -86,10 +86,7 @@ func startServer(socketPath string) error {
}
}
- handle, err := makeDirDriver(config.path)
- if err != nil {
- return errors.Wrapf(err, "error making volume driver")
- }
+ handle := makeDirDriver(config.path)
logrus.Infof("Using %s for volume path", config.path)
server := volume.NewHandler(handle)
@@ -116,12 +113,12 @@ type dirVol struct {
}
// Make a new DirDriver.
-func makeDirDriver(path string) (volume.Driver, error) {
+func makeDirDriver(path string) volume.Driver {
drv := new(DirDriver)
drv.volumesPath = path
drv.volumes = make(map[string]*dirVol)
- return drv, nil
+ return drv
}
// Capabilities returns the capabilities of the driver.