diff options
author | 2017-01-30 18:45:28 +0100 | |
---|---|---|
committer | 2017-01-30 19:56:05 +0100 | |
commit | 41385422ef4d6ac2dced5aa38352343702b26772 (patch) | |
tree | fb91d02beb88fcf6a424940071b76a64ac101887 /dev-python/pygments/files | |
parent | dev-python/pygments: Bump to version 2.2.0 (diff) | |
download | gentoo-41385422ef4d6ac2dced5aa38352343702b26772.tar.gz gentoo-41385422ef4d6ac2dced5aa38352343702b26772.tar.bz2 gentoo-41385422ef4d6ac2dced5aa38352343702b26772.zip |
dev-python/pygments: Removed old.
Package-Manager: Portage-2.3.3, Repoman-2.3.1
Diffstat (limited to 'dev-python/pygments/files')
3 files changed, 0 insertions, 101 deletions
diff --git a/dev-python/pygments/files/2.0.2-bytes-decode.patch b/dev-python/pygments/files/2.0.2-bytes-decode.patch deleted file mode 100644 index 35f2e26aaca5..000000000000 --- a/dev-python/pygments/files/2.0.2-bytes-decode.patch +++ /dev/null @@ -1,16 +0,0 @@ - pygments/formatters/img.py | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/pygments/formatters/img.py b/pygments/formatters/img.py -index db5bee3..12d53cd 100644 ---- a/pygments/formatters/img.py -+++ b/pygments/formatters/img.py -@@ -84,7 +84,7 @@ class FontManager(object): - if not exit: - lines = out.splitlines() - if lines: -- path = lines[0].strip().strip(':') -+ path = lines[0].decode().strip().strip(':') - return path - - def _create_nix(self): diff --git a/dev-python/pygments/files/2.0.2-shell-injection-backport.patch b/dev-python/pygments/files/2.0.2-shell-injection-backport.patch deleted file mode 100644 index 0a23adce330d..000000000000 --- a/dev-python/pygments/files/2.0.2-shell-injection-backport.patch +++ /dev/null @@ -1,29 +0,0 @@ -# HG changeset patch -# User Javantea <jvoss@altsci.com> -# Date 1443460403 25200 -# Node ID 6b4baae517b6aaff7142e66f1dbadf7b9b871f61 -# Parent 655dbebddc23943b8047b3c139c51c22ef18fd91 -Fix Shell Injection in FontManager._get_nix_font_path - -diff --git a/pygments/formatters/img.py b/pygments/formatters/img.py ---- a/pygments/formatters/img.py -+++ b/pygments/formatters/img.py -@@ -10,6 +10,7 @@ - """ - - import sys -+import shlex - - from pygments.formatter import Formatter - from pygments.util import get_bool_opt, get_int_opt, get_list_opt, \ -@@ -79,8 +80,8 @@ - from commands import getstatusoutput - except ImportError: - from subprocess import getstatusoutput -- exit, out = getstatusoutput('fc-list "%s:style=%s" file' % -- (name, style)) -+ exit, out = getstatusoutput('fc-list %s file' % -+ shlex.quote("%s:style=%s" % (name, style))) - if not exit: - lines = out.splitlines() - if lines: diff --git a/dev-python/pygments/files/2.0.2-shell-injection-backport2.patch b/dev-python/pygments/files/2.0.2-shell-injection-backport2.patch deleted file mode 100644 index 78bf4478ecd7..000000000000 --- a/dev-python/pygments/files/2.0.2-shell-injection-backport2.patch +++ /dev/null @@ -1,56 +0,0 @@ -# HG changeset patch -# User Tim Hatch <tim@timhatch.com> -# Date 1445007300 25200 -# Node ID 0036ab1c99e256298094505e5e92fdacdfc5b0a8 -# Parent c0c0d4049a7c325cd69b764c6ceb7747d319212d -Avoid the shell entirely when finding fonts. - -Manually tested on OS X. - -diff --git a/pygments/formatters/img.py b/pygments/formatters/img.py ---- a/pygments/formatters/img.py -+++ b/pygments/formatters/img.py -@@ -10,12 +10,13 @@ - """ - - import sys --import shlex - - from pygments.formatter import Formatter - from pygments.util import get_bool_opt, get_int_opt, get_list_opt, \ - get_choice_opt, xrange - -+import subprocess -+ - # Import this carefully - try: - from PIL import Image, ImageDraw, ImageFont -@@ -76,14 +77,11 @@ - self._create_nix() - - def _get_nix_font_path(self, name, style): -- try: -- from commands import getstatusoutput -- except ImportError: -- from subprocess import getstatusoutput -- exit, out = getstatusoutput('fc-list %s file' % -- shlex.quote("%s:style=%s" % (name, style))) -- if not exit: -- lines = out.splitlines() -+ proc = subprocess.Popen(['fc-list', "%s:style=%s" % (name, style), 'file'], -+ stdout=subprocess.PIPE, stderr=None) -+ stdout, _ = proc.communicate() -+ if proc.returncode == 0: -+ lines = stdout.splitlines() - if lines: - path = lines[0].strip().strip(':') - return path -@@ -198,7 +196,7 @@ - bold and italic fonts will be generated. This really should be a - monospace font to look sane. - -- Default: "Bitstream Vera Sans Mono" -+ Default: "Bitstream Vera Sans Mono" on Windows, Courier New on *nix - - `font_size` - The font size in points to be used. |