diff options
Diffstat (limited to 'deluge/ui/console/commands/config.py')
-rw-r--r-- | deluge/ui/console/commands/config.py | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/deluge/ui/console/commands/config.py b/deluge/ui/console/commands/config.py index 4248edb4f..5d8a6ef62 100644 --- a/deluge/ui/console/commands/config.py +++ b/deluge/ui/console/commands/config.py @@ -61,7 +61,11 @@ def atom(next, token): if token[1] == "-": return int(token[-1], 0) else: - return int(token[1], 0) + if token[1].startswith('0x'): + # Hex number so return unconverted as string. + return token[1].decode("string-escape") + else: + return int(token[1], 0) except ValueError: try: return float(token[-1]) |