Skip to content

Commit f7b2f5b

Browse files
committed
fix: flag to free cStr in Object_getBigNumStringValue
1 parent 791bb41 commit f7b2f5b

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

pandas/_libs/src/vendored/ujson/python/objToJSON.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1915,6 +1915,7 @@ static const char *Object_getBigNumStringValue(JSOBJ obj, JSONTypeContext *tc,
19151915
char *bytes = PyObject_Malloc(*_outLen + 1);
19161916
memcpy(bytes, str, *_outLen + 1);
19171917
GET_TC(tc)->cStr = bytes;
1918+
GET_TC(tc)->freeCStr = 1;
19181919

19191920
Py_DECREF(repr);
19201921

0 commit comments

Comments
 (0)