mirror of
https://github.com/gryf/wicd.git
synced 2025-12-20 04:48:00 +01:00
Merged reyammer's branch lp:~reyammer/wicd/bug-476982: implement password hiding (LP: #476982)
This commit is contained in:
@@ -335,6 +335,7 @@ def _parse_enc_template(enctype):
|
||||
cur_type["fields"] = []
|
||||
cur_type['optional'] = []
|
||||
cur_type['required'] = []
|
||||
cur_type['protected'] = []
|
||||
cur_type['name'] = ""
|
||||
for index, line in enumerate(f):
|
||||
if line.startswith("name") and not cur_type["name"]:
|
||||
@@ -353,6 +354,13 @@ def _parse_enc_template(enctype):
|
||||
# An error occured parsing the optional line.
|
||||
print "Invalid 'optional' line found in template %s" % enctype
|
||||
continue
|
||||
elif line.startswith("protected"):
|
||||
cur_type["protected"] = __parse_field_ent(parse_ent(line, "protected"),
|
||||
field_type="protected")
|
||||
if not cur_type["protected"]:
|
||||
# An error occured parsing the protected line.
|
||||
print "Invalid 'protected' line found in template %s" % enctype
|
||||
continue
|
||||
elif line.startswith("----"):
|
||||
# We're done.
|
||||
break
|
||||
|
||||
Reference in New Issue
Block a user