1
0
mirror of https://github.com/gryf/wicd.git synced 2025-12-24 07:02:29 +01:00

Better fix for the property sanitation

This commit is contained in:
David Paleino
2012-05-04 08:32:45 +02:00
parent 6dcb4941df
commit bca11618be

View File

@@ -433,7 +433,7 @@ def sanitize_config(s):
# s is a dbus.String -- since we don't allow unicode property keys,
# make it simple.
return str(s).translate(None, table)
return s.encode('ascii', 'replace').translate(None, table)
def sanitize_escaped(s):
""" Sanitize double-escaped unicode strings. """