[SCM] morituri/master: Encode directory name when writing to stdout.
js at users.alioth.debian.org
js at users.alioth.debian.org
Sun Oct 19 20:10:15 UTC 2014
The following commit has been merged in the master branch:
commit 7f1521d50f5db0295f3128718b2af95a7091b5d6
Author: Thomas Vander Stichele <thomas (at) apestaart (dot) org>
Date: Mon Dec 16 23:17:43 2013 -0500
Encode directory name when writing to stdout.
Fixes #59 on github.
Saddening to see though that this was exposed because someone put
a unicode dash in an otherwise normal album title. People should stop
abusing unicode just because they can.
diff --git a/morituri/rip/cd.py b/morituri/rip/cd.py
index 1689ae0..0183764 100644
--- a/morituri/rip/cd.py
+++ b/morituri/rip/cd.py
@@ -288,11 +288,12 @@ Install pycdio and run 'rip offset find' to detect your drive's offset.
dirname = os.path.dirname(discName)
if os.path.exists(dirname):
self.stdout.write("Output directory %s already exists\n" %
- dirname)
+ dirname.encode('utf-8'))
logs = glob.glob(os.path.join(dirname, '*.log'))
if logs:
- self.stdout.write("Output directory %s is a finished rip\n" %
- dirname)
+ self.stdout.write(
+ "Output directory %s is a finished rip\n" %
+ dirname.encode('utf-8'))
if not disambiguate:
disambiguate = True
continue
@@ -301,7 +302,8 @@ Install pycdio and run 'rip offset find' to detect your drive's offset.
break
else:
- self.stdout.write("Creating output directory %s\n" % dirname)
+ self.stdout.write("Creating output directory %s\n" %
+ dirname.encode('utf-8'))
os.makedirs(dirname)
break
--
morituri packaging
More information about the pkg-multimedia-commits
mailing list