Show More
@@ -33,7 +33,7 b' class ui(object):' | |||||
33 | else: |
|
33 | else: | |
34 | # we always trust global config files |
|
34 | # we always trust global config files | |
35 | for f in util.rcpath(): |
|
35 | for f in util.rcpath(): | |
36 |
self.readconfig(f, |
|
36 | self.readconfig(f, trust=True) | |
37 | def copy(self): |
|
37 | def copy(self): | |
38 | return ui(self) |
|
38 | return ui(self) | |
39 |
|
39 | |||
@@ -69,7 +69,7 b' class ui(object):' | |||||
69 | 'user %s, group %s\n') % (f, user, group)) |
|
69 | 'user %s, group %s\n') % (f, user, group)) | |
70 | return False |
|
70 | return False | |
71 |
|
71 | |||
72 |
def readconfig(self, filename, root=None, |
|
72 | def readconfig(self, filename, root=None, trust=False, | |
73 | sections = None): |
|
73 | sections = None): | |
74 | try: |
|
74 | try: | |
75 | fp = open(filename) |
|
75 | fp = open(filename) | |
@@ -79,7 +79,7 b' class ui(object):' | |||||
79 | raise |
|
79 | raise | |
80 |
|
80 | |||
81 | cdata = config.config() |
|
81 | cdata = config.config() | |
82 |
trusted = sections or |
|
82 | trusted = sections or trust or self._is_trusted(fp, filename) | |
83 |
|
83 | |||
84 | try: |
|
84 | try: | |
85 | cdata.read(filename, fp, sections=sections) |
|
85 | cdata.read(filename, fp, sections=sections) |
General Comments 0
You need to be logged in to leave comments.
Login now