]> granicus.if.org Git - python/commitdiff
also escape '>', to closer match Apple's plist output
authorJust van Rossum <just@letterror.com>
Tue, 26 Oct 2004 10:11:00 +0000 (10:11 +0000)
committerJust van Rossum <just@letterror.com>
Tue, 26 Oct 2004 10:11:00 +0000 (10:11 +0000)
Lib/plat-mac/plistlib.py

index 08ffb17565c9cd0e25f98053ee7fb99b91c5019b..ffe33e9ea95dfdf852765dc8df98186b099ae175 100644 (file)
@@ -208,6 +208,7 @@ def _escapeAndEncode(text):
     text = text.replace("\r", "\n")         # convert Mac line endings
     text = text.replace("&", "&amp;")       # escape '&'
     text = text.replace("<", "&lt;")        # escape '<'
+    text = text.replace(">", "&gt;")        # escape '>'
     text = _controlStripper.sub("?", text)  # replace control chars with '?'
     return text.encode("utf-8")             # encode as UTF-8