1
0
mirror of https://github.com/ultrajson/ultrajson.git synced 2024-11-26 10:23:45 +01:00
ultrajson/python
Brénainn Woodsend 1876c02e0f Limit loading from bytes-like to just bytes() and bytearray() on PyPy.
Due to a bug in PyPy [1], PyObject_GetBuffer() fails to detect non C
contiguous inputs. Allowing ujson.loads() to run on non-contiguous
buffers such as a strided NumPy array would lead to mayhem. Approximate
the intention of PyObject_GetBuffer() by explicitly checking that the
input is within the set of common bytes-like objects known to be
unconditionally C contiguous.

- [1]: https://foss.heptapod.net/pypy/pypy/-/issues/3872
2022-12-20 23:35:38 +00:00
..
JSONtoObj.c Limit loading from bytes-like to just bytes() and bytearray() on PyPy. 2022-12-20 23:35:38 +00:00
objToJSON.c Fix encoding of infinity (#80). 2022-08-08 22:37:52 +01:00
ujson.c Fix encoding of infinity (#80). 2022-08-08 22:37:52 +01:00
ujson.h Raise JSONDecodeError in place of ValueError on failed decode (#498) 2022-02-05 20:39:05 +00:00
version_template.h Lint trailing-whitespace 2020-05-12 09:21:45 +03:00