Can't you use the penalty setting for the agent? Then you can define your own order... No need to modfy the asterisk source.<br>/Johan<br><br><div class="gmail_quote">2008/6/24 Saúl Ibarra <<a href="mailto:saghul@gmail.com">saghul@gmail.com</a>>:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><div class="Ih2E3d">> The hash is based on the "interface" associated with a queue member. There is a<br>
> way you can edit the code such that you can predict the order of queue members.<br>
> In the function init_queue(), look for the following line:<br>
><br>
> q->members = ao2_container_alloc(37, member_hash_fn, member_cmp_fn);<br>
><br>
> If you change the 37 to a 1, then the result will be that the hash table for<br>
> that queue's members will have one bucket instead of 37. Since all members will<br>
> hash to the same bucket, you essentially will be using a linked list for queue<br>
> members. Members would then be stored in the order in which they are parsed in<br>
> the configuration.<br>
><br>
<br>
</div>Yeah!! It works!! Members are listed ordered by interface!! Now iI<br>
have another little question :) Now when I logout (delete from the<br>
table) and login back again (insert in the table), the member is<br>
inserted in last place. Would there be a way for this member to be<br>
inserted in order? Modifying the hash function maybe?<br>
<br>
Thanks a lot Mark!!<br>
<div class="Ih2E3d"><br>
<br>
--<br>
Saúl -- "Nunca subestimes el ancho de banda de un camión lleno de disketes."<br>
----------------------------------------------------------------<br>
<a href="http://www.saghul.net/" target="_blank">http://www.saghul.net/</a><br>
<br>
_______________________________________________<br>
</div><div><div></div><div class="Wj3C7c">--Bandwidth and Colocation Provided by <a href="http://www.api-digital.com--" target="_blank">http://www.api-digital.com--</a><br>
<br>
AstriCon 2008 - September 22 - 25 Phoenix, Arizona<br>
Register Now: <a href="http://www.astricon.net" target="_blank">http://www.astricon.net</a><br>
<br>
asterisk-dev mailing list<br>
To UNSUBSCRIBE or update options visit:<br>
<a href="http://lists.digium.com/mailman/listinfo/asterisk-dev" target="_blank">http://lists.digium.com/mailman/listinfo/asterisk-dev</a><br>
</div></div></blockquote></div><br>