From: Thomas Huth <[email protected]>

Pylint thinks that the accel variable might be used here without
being set first, since it does not know that skipTest() never
returns. Thus initialize "accel = None" here to make it happy.

Signed-off-by: Thomas Huth <[email protected]>
---
 tests/functional/aarch64/test_smmu.py | 1 +
 1 file changed, 1 insertion(+)

diff --git a/tests/functional/aarch64/test_smmu.py 
b/tests/functional/aarch64/test_smmu.py
index e0f4a922176..87b9b14e7a5 100755
--- a/tests/functional/aarch64/test_smmu.py
+++ b/tests/functional/aarch64/test_smmu.py
@@ -50,6 +50,7 @@ def common_vm_setup(self, kernel, initrd, disk):
         elif kvm_available(self.qemu_bin):
             accel = "kvm"
         else:
+            accel = None        # for keeping pylint happy
             self.skipTest("Neither HVF nor KVM accelerator is available")
         self.require_accelerator(accel)
         self.require_netdev('user')
-- 
2.51.1


Reply via email to