Sophie

Sophie

distrib > Mageia > 6 > armv5tl > by-pkgid > 60b9d01190d3919f4142c2c6039b5f1a > files > 3

m64py-0.2.3-7.mga6.tainted.src.rpm

From 837ab480eb8249f7f7ccfd3db877991d027678a6 Mon Sep 17 00:00:00 2001
From: milseg <mltnczr@gmail.com>
Date: Thu, 14 May 2015 23:27:05 -0300
Subject: [PATCH] UnicodeDecodeError corrected

I've got an UnicodeDecode error for the ascii codec while logging a message while running m64py on Ubuntu versions 14.04+. Adding two lines corrected the problem
---
 src/m64py/core/core.py | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/src/m64py/core/core.py b/src/m64py/core/core.py
index b5207eb..4ebc9bd 100644
--- a/src/m64py/core/core.py
+++ b/src/m64py/core/core.py
@@ -230,6 +230,8 @@ def plugin_load_try(self, plugin_path=None):
                     plugin_handle, plugin_path, PLUGIN_NAME[plugin_type], plugin_desc, plugin_version)
         except OSError as e:
             log.debug("plugin_load_try()")
+            plugin_path = plugin_path.decode('ascii', 'ignore')
+            plugin_path = plugin_path.encode('ascii')
             log.error("failed to load plugin %s: %s" % (plugin_path, e))
 
     def plugin_startup(self, handle, name, desc):