MCPcopy Create free account
hub / github.com/apache/arrow / ErrnoFromStatus

Function ErrnoFromStatus

cpp/src/arrow/util/io_util.cc:477–490  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

475}
476
477int ErrnoFromStatus(const Status& status) {
478 const auto detail = status.detail();
479 if (detail != nullptr) {
480 if (detail->type_id() == kErrnoDetailTypeId) {
481 return checked_cast<const ErrnoDetail&>(*detail).errnum();
482 }
483#if _WIN32
484 if (detail->type_id() == kWinErrorDetailTypeId) {
485 return checked_cast<const WinErrorDetail&>(*detail).equivalent_errno();
486 }
487#endif
488 }
489 return 0;
490}
491
492int WinErrorFromStatus(const Status& status) {
493#if _WIN32

Callers 2

TESTFunction · 0.70
TEST_FFunction · 0.70

Calls 3

equivalent_errnoMethod · 0.80
type_idMethod · 0.45
errnumMethod · 0.45

Tested by 2

TESTFunction · 0.56
TEST_FFunction · 0.56