@henningw commented on this pull request.
Thanks for the PR - I have added a few comments, which also should fix the
clang-format check.
> @@ -2338,15 +2338,15 @@ modparam("rtpengine", "control_cmd_tos", 144)
<section id="rtpengine.p.hash_algo">
<title><varname>hash_algo</varname> (integer)</title>
<para>
- Hashing algorithm to be used in node selection
algorithm. Now there are 3 possibilities: legacy
- algorithm - 0 (very basic hash over callid), SHA1 - 1
(apply sha1 over the callid and calculate hash) or
- CRC32 - 2 (calculate crc32 sum over the callid).
+ Hashing algorithm to be used in node selection
algorithm. Now there are 3 possibilities:
two possibilities
> @@ -2338,15 +2338,15 @@ modparam("rtpengine", "control_cmd_tos", 144)
<section id="rtpengine.p.hash_algo">
<title><varname>hash_algo</varname> (integer)</title>
<para>
- Hashing algorithm to be used in node selection
algorithm. Now there are 3 possibilities: legacy
- algorithm - 0 (very basic hash over callid), SHA1 - 1
(apply sha1 over the callid and calculate hash) or
- CRC32 - 2 (calculate crc32 sum over the callid).
+ Hashing algorithm to be used in node selection
algorithm. Now there are 3 possibilities:
+ SHA1 - 0 (apply sha1 over the callid and calculate
hash) or
We probably should keep the old integer values for compatibility reasons,
otherwise people cfg will break after an update.
> @@ -4485,10 +4485,7 @@ static struct rtpp_node *select_rtpp_node_new(str
> callid, str viabranch,
str hash_data = STR_NULL;
switch(hash_algo) {
- case RTP_HASH_CALLID:
- hash_data = callid;
-
- break;
+
unneeded line break?
> @@ -4510,13 +4507,7 @@ static struct rtpp_node *select_rtpp_node_new(str
> callid, str viabranch,
sum = 0;
for(i = 0; i < hash_data.len; i++)
sum += hash_data.s[i];
-
- /* FIXME this seems to affect the algorithm in a negative way
- * legacy code uses it; disable it for other algos */
- if(hash_algo == RTP_HASH_CALLID) {
- sum &= 0xff;
- }
-
+
unneeded line break?
--
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/pull/4524#pullrequestreview-3578537581
You are receiving this because you are subscribed to this thread.
Message ID: <kamailio/kamailio/pull/4524/review/[email protected]>_______________________________________________
Kamailio - Development Mailing List -- [email protected]
To unsubscribe send an email to [email protected]
Important: keep the mailing list in the recipients, do not reply only to the
sender!