mirror of
https://github.com/containers/podman.git
synced 2025-07-03 17:27:18 +08:00
libpod: fix wastedassign warning on freebsd
This one: > libpod/container_internal_freebsd.go:255:2: assigned to foundUTS, but reassigned without using the value (wastedassign) > foundUTS := false > ^ Signed-off-by: Kir Kolyshkin <kolyshkin@gmail.com>
This commit is contained in:
@ -255,10 +255,9 @@ func (c *Container) addSharedNamespaces(g *generate.Generator) error {
|
|||||||
// the user (already present in OCI spec). If we don't have a UTS ns,
|
// the user (already present in OCI spec). If we don't have a UTS ns,
|
||||||
// set it to the host's hostname instead.
|
// set it to the host's hostname instead.
|
||||||
hostname := c.Hostname()
|
hostname := c.Hostname()
|
||||||
foundUTS := false
|
|
||||||
|
|
||||||
// TODO: make this optional, needs progress on adding FreeBSD section to the spec
|
// TODO: make this optional, needs progress on adding FreeBSD section to the spec
|
||||||
foundUTS = true
|
foundUTS := true
|
||||||
g.SetHostname(hostname)
|
g.SetHostname(hostname)
|
||||||
|
|
||||||
if !foundUTS {
|
if !foundUTS {
|
||||||
|
Reference in New Issue
Block a user