Commits

Christian Hudon committed 1307a54

Remove redundant test for NULL; emulate behavior of CPython 2.7 by only raising an error for control characters < 0x20.

Comments (0)

Files changed (1)

pypy/module/_pypyjson/interp_decoder.py

                 content_so_far = self.getslice(start, i-1)
                 self.pos = i-1
                 return self.decode_string_escaped(start, content_so_far)
-            elif ch == '\0':
-                self._raise("Unterminated string starting at char %d", start)
-            elif ch < '\x20' or ch == '\x7f':
+            elif ch < '\x20':
                 self._raise("Invalid control character at char %d", self.pos-1)