diff mbox series

[3/3] python/sepolicy: fix variable name

Message ID 20190131210753.11221-4-nicolas.iooss@m4x.org (mailing list archive)
State Accepted
Headers show
Series Support flake8 version 3.7 | expand

Commit Message

Nicolas Iooss Jan. 31, 2019, 9:07 p.m. UTC
modify_button_clicked() used variable "type" in a comparison instead of
"ftype". This is a bug, which has been found with flake8 3.7.0. This
linter reported:

    python/sepolicy/sepolicy/gui.py:1548:20: F823 local variable 'type'
    {0} referenced before assignment

Signed-off-by: Nicolas Iooss <nicolas.iooss@m4x.org>
---
 python/sepolicy/sepolicy/gui.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/python/sepolicy/sepolicy/gui.py b/python/sepolicy/sepolicy/gui.py
index fde233ad98b1..d4bf3b48e629 100644
--- a/python/sepolicy/sepolicy/gui.py
+++ b/python/sepolicy/sepolicy/gui.py
@@ -1545,7 +1545,7 @@  class SELinuxGui():
                 path = self.executable_files_liststore.get_value(iter, 0)
                 self.files_path_entry.set_text(path)
                 ftype = self.executable_files_liststore.get_value(iter, 1)
-                if type != None:
+                if ftype != None:
                     self.combo_set_active_text(self.files_type_combobox, ftype)
                 tclass = self.executable_files_liststore.get_value(iter, 2)
                 if tclass != None: