<p></p>
<p><b>@asalman18</b> commented on this pull request.</p>

<hr>

<p>In <a href="https://github.com/kamailio/kamailio/pull/2493#discussion_r520946453">src/modules/dispatcher/dispatch.c</a>:</p>
<pre style='color:#555'>> @@ -2270,6 +2372,15 @@ int ds_manage_routes(sip_msg_t *msg, ds_select_state_t *rstate)
                case DS_ALG_PARALLEL: /* 12 - parallel dispatching */
                        hash = 0;
                        break;
+               case DS_ALG_LATENCY: /* 13 - latency optimized round-robin with failover */
+                       lock_get(&idx->lock);
+                       hash = ds_manage_route_algo13(idx, rstate);
+                       lock_release(&idx->lock);
+                       if (hash < 0)
</pre>
<p>Should we check if hash is -1 and not < 0</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/2493#pullrequestreview-527698135">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe-auth/ABO7UZMUCBIQYEW45VLI27TSPHGJDANCNFSM4SA5ZYNQ">unsubscribe</a>.<img src="https://github.com/notifications/beacon/ABO7UZJ2LISFUL5EOJXTB4LSPHGJDA5CNFSM4SA5ZYN2YY3PNVWWK3TUL52HS4DFWFIHK3DMKJSXC5LFON2FEZLWNFSXPKTDN5WW2ZLOORPWSZGOD52ARVY.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/2493#pullrequestreview-527698135",
"url": "https://github.com/kamailio/kamailio/pull/2493#pullrequestreview-527698135",
"name": "View Pull Request"
},
"description": "View this Pull Request on GitHub",
"publisher": {
"@type": "Organization",
"name": "GitHub",
"url": "https://github.com"
}
}
]</script>