Signed-off-by: Lucas Meneghel Rodrigues <[email protected]>
---
 cli/acl.py |   15 +++++++++------
 1 files changed, 9 insertions(+), 6 deletions(-)

diff --git a/cli/acl.py b/cli/acl.py
index d6f5baa..0b20acf 100644
--- a/cli/acl.py
+++ b/cli/acl.py
@@ -79,23 +79,26 @@ class acl_list(action_common.atest_list, acl):
         (options, leftover) = super(acl_list, self).parse([user_info,
                                                            host_info])
 
-        if ((self.users and (self.hosts or self.acls)) or
-            (self.hosts and self.acls)):
+        users = getattr(self, 'users')
+        hosts = getattr(self, 'hosts')
+        acls = getattr(self, 'acls')
+        if ((users and (hosts or acls)) or
+            (hosts and acls)):
             self.invalid_syntax('Only specify one of --user,'
                                 '--machine or ACL')
 
-        if len(self.users) > 1:
+        if len(users) > 1:
             self.invalid_syntax('Only specify one <user>')
-        if len(self.hosts) > 1:
+        if len(hosts) > 1:
             self.invalid_syntax('Only specify one <machine>')
 
         try:
-            self.users = self.users[0]
+            self.users = users[0]
         except IndexError:
             pass
 
         try:
-            self.hosts = self.hosts[0]
+            self.hosts = hosts[0]
         except IndexError:
             pass
         return (options, leftover)
-- 
1.7.6

_______________________________________________
Autotest mailing list
[email protected]
http://test.kernel.org/cgi-bin/mailman/listinfo/autotest

Reply via email to