From 33e55bc18e72f2cec9b0e832dc42749a246f1c3f Mon Sep 17 00:00:00 2001 From: Zykino Date: Sun, 11 Nov 2018 14:31:51 +0100 Subject: [PATCH] prevent decoding unicode strings since python prefer to crash than doing nothing --- lib/utils.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lib/utils.py b/lib/utils.py index 2a20ad3..08bc82a 100644 --- a/lib/utils.py +++ b/lib/utils.py @@ -199,6 +199,10 @@ def cleanString(toclean): return cleaned def decodeArgumentStrings(options, encoding): + # Python crash when decding from UTF-8 to UTF-8, so we prevent this + if "utf-8" == encoding.lower(): + return; + if options["--name"] is not None: options["--name"] = options["--name"].decode(encoding)