fix get port from free_list of port pool#1579
fix get port from free_list of port pool#1579button-chen wants to merge 1 commit intosipwise:masterfrom button-chen:master
Conversation
|
Can you explain which problem this fixes? Because it's not obvious to me |
For example, if the release_port_now function is called, assuming that the currently released port is A, then the bit array ports_used clears the flag indicating that port A is being used, which is port A When the program continues to execute for a while, Assume that consecutive_ports in the above function __get_consecutive_ports (port += PORT_RANDOM_MIN + (ssl_random() % (PORT_RANDOM_MAX-PORT_RANDOM_MIN)) results in a port Thank you (to google Translate) |
|
Ok, I think I understand. But I'm not sure this approach is correct. The purpose of the bit field If you clear a bit in So I think a different approach is needed here. Perhaps the entire |
|
Thank you for your reply, I think your approach is correct, looking forward to optimizing the code |
|
close |
|
Fixed/improved as of c024b54 |
fix get port from free_list of port pool
Thanks