diff options
author | Richard O'Dwyer <richard@richard.do> | 2015-07-18 12:32:58 +0100 |
---|---|---|
committer | Richard O'Dwyer <richard@richard.do> | 2015-07-18 12:32:58 +0100 |
commit | 939c64ff7a62ab60d892692322d531150d40bd4a (patch) | |
tree | 2e155f0f6d5484dd5391962b09d0737127cfd5b2 | |
parent | ff1e1bf21c1ac82fc9134e4a31bb0243d170723b (diff) | |
download | markupsafe-939c64ff7a62ab60d892692322d531150d40bd4a.tar.gz |
Fixes typo in speedups
-rw-r--r-- | markupsafe/_speedups.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/markupsafe/_speedups.c b/markupsafe/_speedups.c index f349feb..d779a68 100644 --- a/markupsafe/_speedups.c +++ b/markupsafe/_speedups.c @@ -29,7 +29,7 @@ static int init_constants(void) { PyObject *module; - /* happing of characters to replace */ + /* mapping of characters to replace */ escaped_chars_repl['"'] = UNICHR("""); escaped_chars_repl['\''] = UNICHR("'"); escaped_chars_repl['&'] = UNICHR("&"); @@ -41,7 +41,7 @@ init_constants(void) escaped_chars_delta_len['"'] = escaped_chars_delta_len['\''] = \ escaped_chars_delta_len['&'] = 4; escaped_chars_delta_len['<'] = escaped_chars_delta_len['>'] = 3; - + /* import markup type so that we can mark the return value */ module = PyImport_ImportModule("markupsafe"); if (!module) @@ -94,7 +94,7 @@ escape_unicode(PyUnicodeObject *in) } ++next_escp; } - + if (next_escp > inp) { /* copy unescaped chars between inp and next_escp */ Py_UNICODE_COPY(outp, inp, next_escp-inp); |