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

Method setPort

src/tscpp/api/Url.cc:216–229  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

214}
215
216void
217Url::setPort(const uint16_t port)
218{
219 if (!isInitialized()) {
220 LOG_ERROR("Url %p not initialized", this);
221 return;
222 }
223
224 if (TSUrlPortSet(state_->hdr_buf_, state_->url_loc_, port) == TS_SUCCESS) {
225 LOG_DEBUG("Set port to %d", port);
226 } else {
227 LOG_ERROR("Could not set port; hdr_buf %p, url_loc %p", state_->hdr_buf_, state_->url_loc_);
228 }
229}

Callers 1

serverPushMethod · 0.80

Calls 1

TSUrlPortSetFunction · 0.85

Tested by

no test coverage detected