From 331f625f91e1a079424e18779e7d26e120c9e426 Mon Sep 17 00:00:00 2001 From: Sebastian Wiesner Date: Thu, 20 Nov 2008 20:06:36 +0100 Subject: [PATCH] Fixed encoding issue in pngmath hashing --- sphinx/ext/pngmath.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sphinx/ext/pngmath.py b/sphinx/ext/pngmath.py index 77d08eef1..aa0d0c2e6 100644 --- a/sphinx/ext/pngmath.py +++ b/sphinx/ext/pngmath.py @@ -75,7 +75,7 @@ def render_math(self, math): """ use_preview = self.builder.config.pngmath_use_preview - shasum = "%s.png" % sha(math).hexdigest() + shasum = "%s.png" % sha(math.encode('utf-8')).hexdigest() relfn = posixpath.join(self.builder.imgpath, 'math', shasum) outfn = path.join(self.builder.outdir, '_images', 'math', shasum) if path.isfile(outfn):