lidavidm commented on a change in pull request #12237:
URL: https://github.com/apache/arrow/pull/12237#discussion_r791282031



##########
File path: c_glib/arrow-cuda-glib/cuda.cpp
##########
@@ -288,7 +288,9 @@ garrow_cuda_buffer_new(GArrowCUDAContext *context,
   auto arrow_context = garrow_cuda_context_get_raw(context);
   auto arrow_buffer = arrow_context->Allocate(size);
   if (garrow::check(error, arrow_buffer, "[cuda][buffer][new]")) {
-    return garrow_cuda_buffer_new_raw(&(*arrow_buffer));
+    std::shared_ptr<arrow::cuda::CudaBuffer> cuda_buffer =
+      arrow_buffer.MoveValueUnsafe();
+    return garrow_cuda_buffer_new_raw(&cuda_buffer);

Review comment:
       Ah, ok, I've updated it. (There still needs to be a std::move to convert 
from unique_ptr to shared_ptr, though.)




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