Describe the bug, including details regarding any error messages, version, and platform.
arrow::ipc::StreamDecoder::Consume(const uint8_t* data, int64_t size) can't assume the given data is still valid after the next Consume(const uint8_t* data, int64_t size) call. So we need to copy the given data for metadata message. Because the metadata message is used in the next body message. The next body message may be happen in the next Consume(const uint8_t* data, int64_t size) call.
Component(s)
C++