cyb70289 commented on code in PR #13662: URL: https://github.com/apache/arrow/pull/13662#discussion_r929473880
########## cpp/src/arrow/io/file.cc: ########## @@ -167,8 +169,23 @@ class OSFile { if (length < 0) { return Status::IOError("Length must be non-negative"); } +#ifdef __linux__ + if (reuse_) { + return ::arrow::internal::FileWrite(fd_.fd(), + reinterpret_cast<const uint8_t*>(data), length); Review Comment: This line can probably be hoisted above #ifdef, leave only one copy, not three as in current code. -- 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: github-unsubscr...@arrow.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org