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

Function http_hdr_method_get

src/proxy/hdrs/HTTP.cc:694–710  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

692 -------------------------------------------------------------------------*/
693
694const char *
695http_hdr_method_get(HTTPHdrImpl *hh, int *length)
696{
697 const char *str;
698
699 ink_assert(hh->m_polarity == HTTP_TYPE_REQUEST);
700
701 if (hh->u.req.m_method_wks_idx >= 0) {
702 str = hdrtoken_index_to_wks(hh->u.req.m_method_wks_idx);
703 *length = hdrtoken_index_to_length(hh->u.req.m_method_wks_idx);
704 } else {
705 str = hh->u.req.m_ptr_method;
706 *length = hh->u.req.m_len_method;
707 }
708
709 return (str);
710}
711
712/*-------------------------------------------------------------------------
713 -------------------------------------------------------------------------*/

Callers 1

method_getMethod · 0.85

Calls 2

hdrtoken_index_to_wksFunction · 0.85
hdrtoken_index_to_lengthFunction · 0.85

Tested by

no test coverage detected