Show More
@@ -101,6 +101,11 b' class ui(object):' | |||||
101 | return True |
|
101 | return True | |
102 | tusers = self.trusted_users |
|
102 | tusers = self.trusted_users | |
103 | tgroups = self.trusted_groups |
|
103 | tgroups = self.trusted_groups | |
|
104 | if not tusers: | |||
|
105 | user = util.username() | |||
|
106 | if user is not None: | |||
|
107 | self.trusted_users[user] = 1 | |||
|
108 | self.fixconfig(section='trusted') | |||
104 | if (tusers or tgroups) and '*' not in tusers and '*' not in tgroups: |
|
109 | if (tusers or tgroups) and '*' not in tusers and '*' not in tgroups: | |
105 | user = util.username(st.st_uid) |
|
110 | user = util.username(st.st_uid) | |
106 | group = util.groupname(st.st_gid) |
|
111 | group = util.groupname(st.st_gid) | |
@@ -203,14 +208,11 b' class ui(object):' | |||||
203 | self.interactive = self.configbool("ui", "interactive", True) |
|
208 | self.interactive = self.configbool("ui", "interactive", True) | |
204 |
|
209 | |||
205 | # update trust information |
|
210 | # update trust information | |
206 | if section is None or section == 'trusted': |
|
211 | if (section is None or section == 'trusted') and self.trusted_users: | |
207 | user = util.username() |
|
212 | for user in self.configlist('trusted', 'users'): | |
208 | if user is not None: |
|
|||
209 | self.trusted_users[user] = 1 |
|
213 | self.trusted_users[user] = 1 | |
210 |
|
|
214 | for group in self.configlist('trusted', 'groups'): | |
211 |
|
|
215 | self.trusted_groups[group] = 1 | |
212 | for group in self.configlist('trusted', 'groups'): |
|
|||
213 | self.trusted_groups[group] = 1 |
|
|||
214 |
|
216 | |||
215 | def setconfig(self, section, name, value): |
|
217 | def setconfig(self, section, name, value): | |
216 | if not self.overlay: |
|
218 | if not self.overlay: |
General Comments 0
You need to be logged in to leave comments.
Login now