Lines Matching refs:res

160     int res = TEMP_FAILURE_RETRY(read(read_fd_, bdata + nbytes, ndata - nbytes));  in ReadFullyWithoutChecks()  local
161 if (res < 0) { in ReadFullyWithoutChecks()
164 } else if (res == 0) { in ReadFullyWithoutChecks()
167 nbytes += res; in ReadFullyWithoutChecks()
176 int res = TEMP_FAILURE_RETRY(ioctl(read_fd_, FIONREAD, &avail)); in ReadUpToMax() local
177 if (res < 0) { in ReadUpToMax()
186 res = TEMP_FAILURE_RETRY(poll(&pollfd, /*nfds*/1, /*timeout*/0)); in ReadUpToMax()
187 if (res < 0 || (pollfd.revents & POLLERR) == POLLERR) { in ReadUpToMax()
212 IOResult res = ReadUpToMax(reinterpret_cast<uint8_t*>(data) + nbytes, in ReadFully() local
215 if (res != IOResult::kOk) { in ReadFully()
216 return res; in ReadFully()
265 int res = TEMP_FAILURE_RETRY(write(write_fd_, bdata + nbytes, ndata - nbytes)); in WriteFullyWithoutChecks() local
266 if (res < 0) { in WriteFullyWithoutChecks()
269 } else if (res == 0) { in WriteFullyWithoutChecks()
272 nbytes += res; in WriteFullyWithoutChecks()
314 int res = TEMP_FAILURE_RETRY(recvmsg(listen_fd_, &msg, 0)); in ReceiveFdsFromSocket() local
315 if (res <= 0) { in ReceiveFdsFromSocket()
387 IOResult res = ReadFullyWithoutChecks(handshake_recv, sizeof(handshake_recv)); in Accept() local
388 if (res != IOResult::kOk || in Accept()
396 res = WriteFullyWithoutChecks(kJdwpHandshake, sizeof(kJdwpHandshake)); in Accept()
397 if (res != IOResult::kOk) { in Accept()
442 jdwpTransportError res = in Close() local
447 if (res == OK) { in Close()
450 return res; in Close()
501 T HandleResult(IOResult res, T val, T fail) { in HandleResult() argument
502 switch (res) { in HandleResult()
530 IOResult res = transport_->ReadFully(out, rem); in ReadRemaining() local
531 jbyte* ret = HandleResult(res, out, static_cast<jbyte*>(nullptr)); in ReadRemaining()
544 IOResult res = transport_->ReadFully(&out, sizeof(out)); in ReadByte() local
545 return HandleResult(res, NetworkToHost(out), static_cast<jbyte>(-1)); in ReadByte()
553 IOResult res = transport_->ReadFully(&out, sizeof(out)); in ReadInt16() local
554 return HandleResult(res, NetworkToHost(out), static_cast<jshort>(-1)); in ReadInt16()
562 IOResult res = transport_->ReadFully(&out, sizeof(out)); in ReadInt32() local
563 return HandleResult(res, NetworkToHost(out), -1); in ReadInt32()
602 IOResult res = transport_->WriteFully(data_.data(), data_.size()); in WriteFully() local
603 return res == IOResult::kOk; in WriteFully()