pitrou commented on code in PR #40412:
URL: https://github.com/apache/arrow/pull/40412#discussion_r1517490377


##########
python/pyarrow/src/arrow/python/python_to_arrow.cc:
##########
@@ -1114,6 +1115,7 @@ class PyStructConverter : public 
StructConverter<PyConverter, PyConverterTrait>
 
   Result<std::pair<PyObject*, PyObject*>> GetKeyValuePair(PyObject* seq, int 
index) {
     PyObject* pair = PySequence_GetItem(seq, index);
+    OwnedRef pair_ref(pair);

Review Comment:
   Should be moved just below `RETURN_IF_PYERROR`.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to