@piotrgregor: thanks for looking into it!
One question: I understand that the change would be better in the libstirshaken, but till that is done, because it may take some time, we can have this in Kamailio module, right?
I mean, from the c code point of view, all is fine with the PR.
Once the library is updated, the code of Kamailio module can be changed again.