mirror of
https://github.com/kata-containers/kata-containers.git
synced 2025-06-29 16:57:18 +00:00
lint: Fix virtcontainers staticcheck
errors
Correct `staticcheck` linter issues. Signed-off-by: James O. D. Hunt <james.o.hunt@intel.com>
This commit is contained in:
parent
d51a5e303d
commit
b1628639e8
@ -112,6 +112,6 @@ func TestAssetNew(t *testing.T) {
|
||||
},
|
||||
}
|
||||
|
||||
a, err = newAsset(p, kernelAsset)
|
||||
_, err = newAsset(p, kernelAsset)
|
||||
assert.NotNil(err)
|
||||
}
|
||||
|
@ -22,7 +22,7 @@ type bridgeType string
|
||||
|
||||
const (
|
||||
pciBridge bridgeType = "pci"
|
||||
pcieBridge = "pcie"
|
||||
pcieBridge bridgeType = "pcie"
|
||||
)
|
||||
|
||||
const pciBridgeMaxCapacity = 30
|
||||
|
@ -485,7 +485,7 @@ func (h *Hyperstart) WaitForPAE(containerID, processID string) (*PAECommand, err
|
||||
msg := <-channel
|
||||
|
||||
var paeData PAECommand
|
||||
err = json.Unmarshal(msg.Message, paeData)
|
||||
err = json.Unmarshal(msg.Message, &paeData)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
@ -78,7 +78,7 @@ func (m *multicast) buildEventID(containerID, processID string) string {
|
||||
func (m *multicast) sendEvent(msg *DecodedMessage) error {
|
||||
var paeData PAECommand
|
||||
|
||||
err := json.Unmarshal(msg.Message, paeData)
|
||||
err := json.Unmarshal(msg.Message, &paeData)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
@ -52,10 +52,10 @@ type NSType string
|
||||
// without multithreading issues.
|
||||
const (
|
||||
NSTypeCGroup NSType = "cgroup"
|
||||
NSTypeIPC = "ipc"
|
||||
NSTypeNet = "net"
|
||||
NSTypePID = "pid"
|
||||
NSTypeUTS = "uts"
|
||||
NSTypeIPC NSType = "ipc"
|
||||
NSTypeNet NSType = "net"
|
||||
NSTypePID NSType = "pid"
|
||||
NSTypeUTS NSType = "uts"
|
||||
)
|
||||
|
||||
// CloneFlagsTable is exported so that consumers of this package don't need
|
||||
|
Loading…
Reference in New Issue
Block a user