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


##########
cpp/src/arrow/util/compression_zstd.cc:
##########
@@ -235,13 +226,53 @@ class ZSTDCodec : public Codec {
   int compression_level() const override { return compression_level_; }
 
  private:
+  Result<CCtxPtr> CreateCCtx() const {
+    CCtxPtr cctx{ZSTD_createCCtx(), ZSTD_freeCCtx};
+    if (cctx == nullptr) {
+      return Status::IOError("ZSTD_CCtx create failed: Unknown error");

Review Comment:
   Given the above, `Status::OutOfMemory` seems more appropriate?



-- 
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