mirror of
https://github.com/capstone-engine/llvm-capstone.git
synced 2024-11-25 14:50:26 +00:00
Convert old python3 cgi method into the new html one
Summary: Patch by Gianfranco Costamagna Reviewers: serge-sans-paille Reviewed By: serge-sans-paille Subscribers: llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D76126
This commit is contained in:
parent
081efa7dd0
commit
4b428e8f18
@ -3,9 +3,9 @@
|
||||
from __future__ import print_function
|
||||
|
||||
import argparse
|
||||
import cgi
|
||||
import errno
|
||||
import functools
|
||||
import html
|
||||
import io
|
||||
from multiprocessing import cpu_count
|
||||
import os.path
|
||||
@ -197,7 +197,7 @@ class IndexRenderer:
|
||||
self.max_hottest_remarks_on_index = max_hottest_remarks_on_index
|
||||
|
||||
def render_entry(self, r, odd):
|
||||
escaped_name = cgi.escape(r.DemangledFunctionName)
|
||||
escaped_name = html.escape(r.DemangledFunctionName)
|
||||
print(u'''
|
||||
<tr>
|
||||
<td class=\"column-entry-{odd}\"><a href={r.Link}>{r.DebugLocString}</a></td>
|
||||
|
@ -11,7 +11,7 @@ except ImportError:
|
||||
print("For faster parsing, you may want to install libYAML for PyYAML")
|
||||
from yaml import Loader
|
||||
|
||||
import cgi
|
||||
import html
|
||||
from collections import defaultdict
|
||||
import fnmatch
|
||||
import functools
|
||||
@ -159,7 +159,7 @@ class Remark(yaml.YAMLObject):
|
||||
(key, value) = list(mapping.items())[0]
|
||||
|
||||
if key == 'Caller' or key == 'Callee' or key == 'DirectCallee':
|
||||
value = cgi.escape(self.demangle(value))
|
||||
value = html.escape(self.demangle(value))
|
||||
|
||||
if dl and key != 'Caller':
|
||||
dl_dict = dict(list(dl))
|
||||
|
Loading…
Reference in New Issue
Block a user