File tree Expand file tree Collapse file tree 2 files changed +2
-0
lines changed
pandas/_libs/src/ujson/python Expand file tree Collapse file tree 2 files changed +2
-0
lines changed Original file line number Diff line number Diff line change 966966- Bug in :func: `read_json ` raising ``ValueError `` when attempting to parse json strings containing "://" (:issue: `36271 `)
967967- Bug in :func: `read_csv ` when ``engine="c" `` and ``encoding_errors=None `` which caused a segfault (:issue: `45180 `)
968968- Bug in :func: `read_csv ` an invalid value of ``usecols `` leading to an unclosed file handle (:issue: `45384 `)
969+ - Bug in :meth: `DataFrame.to_json ` fix memory leak (:issue: `43877 `)
969970
970971Period
971972^^^^^^
Original file line number Diff line number Diff line change @@ -228,6 +228,7 @@ static PyObject *get_values(PyObject *obj) {
228228 PyErr_Clear ();
229229 } else if (PyObject_HasAttrString (values , "__array__" )) {
230230 // We may have gotten a Categorical or Sparse array so call np.array
231+ Py_DECREF (values );
231232 values = PyObject_CallMethod (values , "__array__" , NULL );
232233 } else if (!PyArray_CheckExact (values )) {
233234 // Didn't get a numpy array, so keep trying
You can’t perform that action at this time.
0 commit comments