Attention is currently required from: laforge, pespin.
neels has posted comments on this change. ( https://gerrit.osmocom.org/c/libosmo-sccp/+/32320 )
Change subject: sccp_scoc.c: fix infinite loop on conn ID exhaustion ......................................................................
Patch Set 1:
(1 comment)
Commit Message:
https://gerrit.osmocom.org/c/libosmo-sccp/+/32320/comment/55004c17_3a0e5a67 PS1, Line 17: entire SCCP conn id number space before exiting in failure.
I don't think it should be configurable. […]
In some programs we have sanity counters to limit iterations to find an unused ID, I think like 1000 or 10000 or some such, so I thought it might be a good idea. AFAICT not for SCCP though, more the other protocols...
I've been hitting this issue of finding an unused ID a lot, and it is in theory a pretty hard problem to make this always O(1). But I've been thinking on-and-off about a general API that will in "all" practical situations be O(1), completely avoiding a lookup whether an ID is used. So yes, ok, if the way to find an unused ID changes and does not require a max_iterations argument at all, then you're probably right and we shouldn't put that parameter there at all.