<p></p>
<p>There are several misunderstanding of the code</p>
<p>As I mentioned, I didn't find a function to do hash natively over an integer, so I used a string. I also asked, if there was any I could use, but received no answer. I guess std::hash is out of the question.</p>
<p>It's wrong to consider that hash will be done over "1", "2", "3", etc. Those are the indexes to the servers. I am not doing a hash over the indexes, but over the original hashes.</p>
<p>Also, my fault. maxRehash has a very misleading name. It was born as a "max", but then used as a counter. If Daniel could have read two lines above :</p>
<pre><code>                         maxRehash--;
                        }
                        while (( maxRehash > 0 ) && ds_skip_dst(idx->dlist[fullHash % listSize].flags ) );

</code></pre>
<p>It's impossible to have there an infinite loop.</p>
<p>I don't like it as a new algorithm. And it has no sense to use it with other algorithms. It has sense only wth hash algorithms.</p>
<p>Forget the request. I withdraw it. I will use a patched version at my work.</p>

<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">—<br />You are receiving this because you are subscribed to this thread.<br />Reply to this email directly, <a href="https://github.com/kamailio/kamailio/pull/2363#issuecomment-656224485">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe-auth/ABO7UZIKHXHYJ5P3N7MY56DR2XVKZANCNFSM4OATJVEA">unsubscribe</a>.<img src="https://github.com/notifications/beacon/ABO7UZIKIXUJQOWKPPKSMH3R2XVKZA5CNFSM4OATJVEKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOE4OTBZI.gif" height="1" width="1" alt="" /></p>
<script type="application/ld+json">[
{
"@context": "http://schema.org",
"@type": "EmailMessage",
"potentialAction": {
"@type": "ViewAction",
"target": "https://github.com/kamailio/kamailio/pull/2363#issuecomment-656224485",
"url": "https://github.com/kamailio/kamailio/pull/2363#issuecomment-656224485",
"name": "View Pull Request"
},
"description": "View this Pull Request on GitHub",
"publisher": {
"@type": "Organization",
"name": "GitHub",
"url": "https://github.com"
}
}
]</script>