wgtmac commented on code in PR #942:
URL: https://github.com/apache/iceberg-cpp/pull/942#discussion_r4305282559
##########
src/iceberg/avro/avro_writer.cc:
##########
@@ -229,6 +232,11 @@ class AvroWriter::Impl {
}
Status Write(ArrowArray* data) {
+ internal::ArrowArrayGuard data_guard(data);
Review Comment:
'AlignBatchForWrite' consumes and releases 'data' even when it returns an
error, but this outer guard still owns the same array. A missing required field
or unknown input field therefore releases it in the helper and again here.
--
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]