Skip to content

Commit

Permalink
Address #3186: don't terminate extracted text at chr(0) characters.
Browse files Browse the repository at this point in the history
  • Loading branch information
julian-smith-artifex-com committed Feb 20, 2024
1 parent 1a69258 commit 25adc23
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 3 deletions.
3 changes: 0 additions & 3 deletions src/__init__.py
Expand Up @@ -17818,9 +17818,6 @@ def PyUnicode_DecodeRawUnicodeEscape(s, errors='strict'):
elif isinstance(s, bytes):
rc = s[:]
ret = rc.decode('raw_unicode_escape', errors=errors)
z = ret.find(chr(0))
if z >= 0:
ret = ret[:z]
return ret


Expand Down
Binary file added tests/resources/test_3186.pdf
Binary file not shown.

0 comments on commit 25adc23

Please sign in to comment.