Home
last modified time | relevance | path

Searched refs:hash (Results 1 – 25 of 25) sorted by path

/unit/src/java/
H A Dnxt_jni_HeaderNamesEnumeration.c101 && f[pos].hash == f[pos - 1].hash in nxt_java_HeaderNamesEnumeration_nextElementPos()
124 && f[pos].hash == f[pos - 1].hash in nxt_java_HeaderNamesEnumeration_nextElement()
H A Dnxt_jni_HeadersEnumeration.c103 if (f->hash != init_field->hash in nxt_java_HeadersEnumeration_nextElementPos()
138 if (f->hash != init_field->hash in nxt_java_HeadersEnumeration_nextElement()
H A Dnxt_jni_Response.c400 f->hash = nxt_unit_field_hash(name, name_len); in nxt_java_add_int_header()
/unit/src/nodejs/unit-http/
H A Dunit.cpp796 uint16_t hash; in response_send_headers() local
854 hash = nxt_unit_field_hash(name_ptr, name_len); in response_send_headers()
879 f->hash = hash; in response_send_headers()
905 f->hash = hash; in response_send_headers()
/unit/src/
H A Dnxt_conf.c1501 nxt_lvlhsh_t hash; in nxt_conf_json_parse_object() local
1511 nxt_lvlhsh_init(&hash); in nxt_conf_json_parse_object()
1558 rc = nxt_conf_object_hash_add(mp_temp, &hash, member); in nxt_conf_json_parse_object()
1654 element = nxt_lvlhsh_each(&hash, &lhe); in nxt_conf_json_parse_object()
H A Dnxt_conf_validation.c1599 nxt_lvlhsh_t hash; member
1615 nxt_lvlhsh_init(&ctx.hash); in nxt_conf_vldt_mtypes()
1684 dup_type = nxt_http_static_mtype_get(&ctx->hash, &exten); in nxt_conf_vldt_mtypes_extension()
1693 return nxt_http_static_mtypes_hash_add(ctx->pool, &ctx->hash, &exten, in nxt_conf_vldt_mtypes_extension()
H A Dnxt_djb_hash.c13 uint32_t hash; in nxt_djb_hash() local
17 hash = NXT_DJB_HASH_INIT; in nxt_djb_hash()
20 hash = nxt_djb_hash_add(hash, *p++); in nxt_djb_hash()
24 return hash; in nxt_djb_hash()
32 uint32_t hash; in nxt_djb_hash_lowcase() local
36 hash = NXT_DJB_HASH_INIT; in nxt_djb_hash_lowcase()
40 hash = nxt_djb_hash_add(hash, nxt_lowcase(c)); in nxt_djb_hash_lowcase()
44 return hash; in nxt_djb_hash_lowcase()
H A Dnxt_djb_hash.h21 #define nxt_djb_hash_add(hash, val) \ argument
22 ((uint32_t) ((((hash) << 5) + (hash)) ^ (uint32_t) (val)))
H A Dnxt_http.h209 uint16_t hash; member
399 nxt_int_t nxt_http_static_mtypes_init(nxt_mp_t *mp, nxt_lvlhsh_t *hash);
400 nxt_int_t nxt_http_static_mtypes_hash_add(nxt_mp_t *mp, nxt_lvlhsh_t *hash,
402 nxt_str_t *nxt_http_static_mtype_get(nxt_lvlhsh_t *hash,
H A Dnxt_http_parse.c524 uint32_t hash; in nxt_http_parse_field_name() local
542 hash = rp->field_hash; in nxt_http_parse_field_name()
560 hash = nxt_http_field_hash_char(hash, c); in nxt_http_parse_field_name()
587 rp->field_hash = hash; in nxt_http_parse_field_name()
607 rp->field_hash = hash; in nxt_http_parse_field_name()
804 field->hash = nxt_http_field_hash_end(rp->field_hash); in nxt_http_parse_field_end()
1180 nxt_http_fields_hash(nxt_lvlhsh_t *hash, in nxt_http_fields_hash() argument
1206 ret = nxt_lvlhsh_insert(hash, &lhq); in nxt_http_fields_hash()
1218 nxt_http_fields_hash_collisions(nxt_lvlhsh_t *hash, in nxt_http_fields_hash_collisions() argument
1250 if (nxt_lvlhsh_insert(hash, &lhq) == NXT_DECLINED) { in nxt_http_fields_hash_collisions()
[all …]
H A Dnxt_http_parse.h88 uint16_t hash; member
123 nxt_int_t nxt_http_fields_hash(nxt_lvlhsh_t *hash,
125 nxt_uint_t nxt_http_fields_hash_collisions(nxt_lvlhsh_t *hash,
127 nxt_int_t nxt_http_fields_process(nxt_list_t *fields, nxt_lvlhsh_t *hash,
138 nxt_http_field_process(nxt_http_field_t *field, nxt_lvlhsh_t *hash, void *ctx) in nxt_http_field_process() argument
145 lhq.key_hash = field->hash; in nxt_http_field_process()
149 if (nxt_lvlhsh_find(hash, &lhq) != NXT_OK) { in nxt_http_field_process()
H A Dnxt_http_request.c936 uint32_t hash; in nxt_http_arguments_parse() local
1016 hash = nxt_http_field_hash_char(hash, *dst); in nxt_http_arguments_parse()
1047 nv->hash = nxt_http_field_hash_end(hash) & 0xFFFF; in nxt_http_argument()
1155 uint32_t hash; in nxt_http_cookie() local
1170 hash = nxt_http_field_hash_char(hash, c); in nxt_http_cookie()
1173 nv->hash = nxt_http_field_hash_end(hash) & 0xFFFF; in nxt_http_cookie()
1190 uint32_t hash; in nxt_http_field_hash() local
1211 hash = nxt_http_field_hash_char(hash, c); in nxt_http_field_hash()
1254 hash = nxt_http_field_hash_char(hash, c); in nxt_http_field_hash()
1278 uint32_t i, hash; in nxt_http_header_hash() local
[all …]
H A Dnxt_http_route.c83 uint16_t hash; member
101 uint16_t hash; member
801 int64_t hash; in nxt_http_route_rule_name_create() local
811 hash = nxt_http_field_hash(mp, name, case_sensitive, encoding); in nxt_http_route_rule_name_create()
812 if (nxt_slow_path(hash == -1)) { in nxt_http_route_rule_name_create()
816 rule->u.name.hash = hash; in nxt_http_route_rule_name_create()
1928 if (rule->u.name.hash != f->hash in nxt_http_route_header()
1979 if (rule->u.name.hash == nv->hash in nxt_http_route_test_argument()
2057 if (rule->u.name.hash == nv->hash in nxt_http_route_test_cookie()
H A Dnxt_http_static.c929 nxt_http_static_mtypes_init(nxt_mp_t *mp, nxt_lvlhsh_t *hash) in nxt_http_static_mtypes_init() argument
1007 ret = nxt_http_static_mtypes_hash_add(mp, hash, &exten, type); in nxt_http_static_mtypes_init()
1034 nxt_http_static_mtypes_hash_add(nxt_mp_t *mp, nxt_lvlhsh_t *hash, in nxt_http_static_mtypes_hash_add() argument
1055 return nxt_lvlhsh_insert(hash, &lhq); in nxt_http_static_mtypes_hash_add()
1060 nxt_http_static_mtype_get(nxt_lvlhsh_t *hash, const nxt_str_t *exten) in nxt_http_static_mtype_get() argument
1071 if (nxt_lvlhsh_find(hash, &lhq) == NXT_OK) { in nxt_http_static_mtype_get()
H A Dnxt_http_variables.c140 int64_t hash; in nxt_http_unknown_var_ref() local
177 hash = nxt_http_header_hash(mp, &str); in nxt_http_unknown_var_ref()
178 if (nxt_slow_path(hash == -1)) { in nxt_http_unknown_var_ref()
193 hash = nxt_http_argument_hash(mp, &str); in nxt_http_unknown_var_ref()
194 if (nxt_slow_path(hash == -1)) { in nxt_http_unknown_var_ref()
209 hash = nxt_http_cookie_hash(mp, &str); in nxt_http_unknown_var_ref()
210 if (nxt_slow_path(hash == -1)) { in nxt_http_unknown_var_ref()
218 ref->data = nxt_var_field_new(mp, &str, (uint32_t) hash); in nxt_http_unknown_var_ref()
630 if (vf->hash == nv->hash in nxt_http_var_arg()
661 if (vf->hash == f->hash in nxt_http_var_header()
[all …]
H A Dnxt_router.c2429 uint32_t hash; in nxt_router_conf_forward_header() local
2436 hash = NXT_HTTP_FIELD_HASH_INIT; in nxt_router_conf_forward_header()
2440 hash = nxt_http_field_hash_char(hash, nxt_lowcase(c)); in nxt_router_conf_forward_header()
2443 hash = nxt_http_field_hash_end(hash) & 0xFFFF; in nxt_router_conf_forward_header()
2445 fh->header_hash = hash; in nxt_router_conf_forward_header()
4141 field->hash = f->hash; in nxt_router_response_ready_handler()
5523 dst_field->hash = field->hash; in nxt_router_prepare_msg()
5542 (int) field->hash, (int) field->skip, in nxt_router_prepare_msg()
5586 || dup->hash != field->hash in nxt_router_prepare_msg()
H A Dnxt_unit.c1926 uint32_t hash; in nxt_unit_field_hash() local
1934 hash = (hash << 4) + hash + nxt_lowcase(ch); in nxt_unit_field_hash()
1937 hash = (hash >> 16) ^ hash; in nxt_unit_field_hash()
1939 return hash; in nxt_unit_field_hash()
1963 switch (fields[i].hash) { in nxt_unit_request_group_dup_fields()
1996 if (fields[i].hash != fields[j].hash in nxt_unit_request_group_dup_fields()
2180 f->hash = src->hash; in nxt_unit_response_realloc()
6399 if (nxt_fast_path(port_id->hash != 0)) { in nxt_unit_port_hash_lhq()
6400 lhq->key_hash = port_id->hash; in nxt_unit_port_hash_lhq()
6405 port_id->hash = lhq->key_hash; in nxt_unit_port_hash_lhq()
[all …]
H A Dnxt_unit.h70 uint32_t hash; member
H A Dnxt_unit_field.h23 uint16_t hash; member
H A Dnxt_var.c172 nxt_var_field_new(nxt_mp_t *mp, nxt_str_t *name, uint32_t hash) in nxt_var_field_new() argument
187 field->hash = hash; in nxt_var_field_new()
248 ret = nxt_lvlhsh_insert(&cache->hash, &lhq); in nxt_var_cache_value()
H A Dnxt_var.h38 uint16_t hash; member
44 nxt_lvlhsh_t hash; member
54 uint32_t hash);
/unit/src/python/
H A Dnxt_python_asgi.c781 if (f->hash == NXT_UNIT_HASH_WS_PROTOCOL in nxt_py_asgi_create_http_scope()
1330 if (req->response->fields[i].hash == NXT_UNIT_HASH_CONTENT_LENGTH) { in nxt_py_asgi_add_field()
H A Dnxt_python_wsgi.c666 if (f2->hash != f->hash in nxt_python_get_environ()
1108 if (pctx->req->response->fields[i].hash == NXT_UNIT_HASH_CONTENT_LENGTH) { in nxt_python_response_add_field()
/unit/src/test/
H A Dnxt_http_parse_test.c53 nxt_str_t *request, nxt_lvlhsh_t *hash, const char *name, nxt_uint_t n);
534 nxt_lvlhsh_t hash; in nxt_http_parse_test() local
587 nxt_memzero(&hash, sizeof(nxt_lvlhsh_t)); in nxt_http_parse_test()
589 colls = nxt_http_fields_hash_collisions(&hash, in nxt_http_parse_test()
594 nxt_memzero(&hash, sizeof(nxt_lvlhsh_t)); in nxt_http_parse_test()
596 lvl_colls = nxt_http_fields_hash_collisions(&hash, in nxt_http_parse_test()
605 nxt_memzero(&hash, sizeof(nxt_lvlhsh_t)); in nxt_http_parse_test()
607 rc = nxt_http_fields_hash(&hash, nxt_http_test_bench_fields, in nxt_http_parse_test()
614 &hash, "simple", 1000000) in nxt_http_parse_test()
621 &hash, "big", 100000) in nxt_http_parse_test()
[all …]
/unit/src/wasm-wasi-component/
H A DCargo.lock126 "rustc-hash",
1086 "rustc-hash",
1141 name = "rustc-hash"