wok diff wicd/stuff/dbus_string_fix.patch @ rev 25578
Remove nimrod
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Sun May 14 19:10:16 2023 +0000 (18 months ago) |
parents | |
children |
line diff
1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/wicd/stuff/dbus_string_fix.patch Sun May 14 19:10:16 2023 +0000 1.3 @@ -0,0 +1,15 @@ 1.4 +=== modified file 'wicd/misc.py' 1.5 +--- wicd/misc.py 2012-04-30 19:20:47 +0000 1.6 ++++ wicd/misc.py 2012-05-03 16:01:49 +0000 1.7 +@@ -430,7 +430,10 @@ 1.8 + """ Sanitize property names to be used in config-files. """ 1.9 + allowed = string.ascii_letters + '_' + string.digits 1.10 + table = string.maketrans(allowed, ' ' * len(allowed)) 1.11 +- return s.translate(None, table) 1.12 ++ 1.13 ++ # s is a dbus.String -- since we don't allow unicode property keys, 1.14 ++ # make it simple. 1.15 ++ return str(s).translate(None, table) 1.16 + 1.17 + def sanitize_escaped(s): 1.18 + """ Sanitize double-escaped unicode strings. """