MCPcopy Create free account
hub / github.com/apache/trafficserver / do_io_write

Method do_io_write

src/proxy/http3/Http3Transaction.cc:141–164  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

139}
140
141VIO *
142HQTransaction::do_io_write(Continuation *c, int64_t nbytes, IOBufferReader *buf, bool /* owner ATS_UNUSED */)
143{
144 if (buf) {
145 this->_write_vio.set_reader(buf);
146 } else {
147 this->_write_vio.buffer.clear();
148 }
149
150 this->_write_vio.mutex = c ? c->mutex : this->mutex;
151 this->_write_vio.cont = c;
152 this->_write_vio.nbytes = nbytes;
153 this->_write_vio.ndone = 0;
154 this->_write_vio.vc_server = this;
155 this->_write_vio.op = VIO::WRITE;
156
157 if (c != nullptr && nbytes > 0) {
158 // TODO Return nullptr if the stream is not on writable state
159 this->_process_write_vio();
160 this->_schedule_write_ready_event();
161 }
162
163 return &this->_write_vio;
164}
165
166void
167HQTransaction::do_io_close(int /* lerrno ATS_UNUSED */)

Callers 1

startMethod · 0.45

Calls 4

_process_write_vioMethod · 0.80
set_readerMethod · 0.45
clearMethod · 0.45

Tested by

no test coverage detected