raulcd commented on PR #49491:
URL: https://github.com/apache/arrow/pull/49491#issuecomment-4046690383
@tadeja can you try applying the following:
```diff
$ git diff
diff --git a/cpp/src/arrow/engine/substrait/expression_internal.cc
b/cpp/src/arrow/engine/substrait/expression_internal.cc
index d91edbfce6..8ad7c93780 100644
--- a/cpp/src/arrow/engine/substrait/expression_internal.cc
+++ b/cpp/src/arrow/engine/substrait/expression_internal.cc
@@ -804,7 +804,13 @@ struct ScalarToProtoImpl {
auto user_defined = std::make_unique<Lit::UserDefined>();
user_defined->set_type_reference(anchor);
auto value_any = std::make_unique<google::protobuf::Any>();
+#if PROTOBUF_VERSION >= 3015000
+ if (!value_any.PackFrom(value)) {
+ return Status::IOError("Failed to pack user defined value");
+ }
+#else
value_any->PackFrom(value);
+#endif
user_defined->set_allocated_value(value_any.release());
lit_->set_allocated_user_defined(user_defined.release());
return Status::OK();
```
--
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]