MCPcopy Create free account
hub / github.com/catboost/catboost / ReadVectorD

Function ReadVectorD

library/cpp/coroutine/engine/network.cpp:112–132  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

110
111
112 TContIOStatus ReadVectorD(TCont* cont, SOCKET fd, TContIOVector* vec, TInstant deadline) noexcept {
113 while (true) {
114 ssize_t res = DoReadVector(fd, vec);
115
116 if (res >= 0) {
117 return TContIOStatus::Success((size_t) res);
118 }
119
120 {
121 const int err = LastSystemError();
122
123 if (!IsBlocked(err)) {
124 return TContIOStatus::Error(err);
125 }
126 }
127
128 if ((res = PollD(cont, fd, CONT_POLL_READ, deadline)) != 0) {
129 return TContIOStatus::Error((int) res);
130 }
131 }
132 }
133
134 TContIOStatus ReadVectorT(TCont* cont, SOCKET fd, TContIOVector* vec, TDuration timeOut) noexcept {
135 return ReadVectorD(cont, fd, vec, timeOut.ToDeadLine());

Callers 3

ReadVectorTFunction · 0.85
ReadVectorIFunction · 0.85
ReadDFunction · 0.85

Calls 5

DoReadVectorFunction · 0.85
LastSystemErrorFunction · 0.85
IsBlockedFunction · 0.70
PollDFunction · 0.70
ErrorClass · 0.50

Tested by

no test coverage detected