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

Function url_CryptoHash_get_92

src/proxy/hdrs/URL.cc:1979–1996  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1977}
1978
1979void
1980url_CryptoHash_get_92(const URLImpl *url, CryptoHash *hash, bool ignore_query, cache_generation_t generation)
1981{
1982 URLHashContext ctx;
1983 if ((url_hash_method != 0) && (url->m_url_type == URL_TYPE_HTTP) &&
1984 ((url->m_len_user + url->m_len_password + url->m_len_params + (ignore_query ? 0 : url->m_len_query)) == 0) &&
1985 (10u + url->m_len_scheme + url->m_len_host + url->m_len_path < BUFSIZE) &&
1986 (memchr(url->m_ptr_host, '%', url->m_len_host) == nullptr) && (memchr(url->m_ptr_path, '%', url->m_len_path) == nullptr)) {
1987 url_CryptoHash_get_fast(url, ctx, hash, generation);
1988#ifdef DEBUG
1989 CryptoHash hash_general;
1990 url_CryptoHash_get_general_92(url, ctx, hash_general, ignore_query, generation);
1991 ink_assert(*hash == hash_general);
1992#endif
1993 } else {
1994 url_CryptoHash_get_general_92(url, ctx, *hash, ignore_query, generation);
1995 }
1996}
1997
1998/*-------------------------------------------------------------------------
1999 -------------------------------------------------------------------------*/

Callers 1

hash_get92Method · 0.85

Calls 2

url_CryptoHash_get_fastFunction · 0.85

Tested by

no test coverage detected