Uh oh!
There was an error while loading. Please reload this page.
ARROW-15115: [C++] GcsFileSystem return errors if using closed streams - #11976
ARROW-15115: [C++] GcsFileSystem return errors if using closed streams#11976coryan wants to merge 2 commits into
Conversation
| } | ||
| bool closed() const override { return !stream_.IsOpen(); } | ||
| bool closed() const override { return closed_ && !stream_.IsOpen(); } |
There was a problem hiding this comment.
Is there a reason this is && rather than ||?
There was a problem hiding this comment.
Yes. zero-length objects are "born closed" in google-cloud-cpp. Probably a bug (or at least a very poorly thought API), but you can read() from them, while they return IsOpen() == false.
There was a problem hiding this comment.
Ah, can you add a comment about that?
There was a problem hiding this comment.
Done. That got me thinking about the similar expression for output streams, and you were right in that case. Fixed that too.
Benchmark runs are scheduled for baseline = 61745be and contender = 04641a3. 04641a3 is a master commit associated with this PR. Results will be available as each benchmark for each run completes. |
No description provided.