MCPcopy Create free account
hub / github.com/3proxy/3proxy / hashindex

Function hashindex

src/auth.c:884–891  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

882}
883
884unsigned hashindex(struct hashtable *ht, const unsigned char* hash){
885 unsigned t1, t2, t3, t4;
886 t1 = *(unsigned *)hash;
887 t2 = *(unsigned *)(hash + sizeof(unsigned));
888 t3 = *(unsigned *)(hash + (2*sizeof(unsigned)));
889 t4 = *(unsigned *)(hash + (3*sizeof(unsigned)));
890 return (t1 + (t2 * 7) + (t3 * 17) + (t4 * 29) ) % (ht->hashsize >> 2);
891}
892
893
894void destroyhashtable(struct hashtable *ht){

Callers 2

hashaddFunction · 0.85
hashresolvFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected