[sr-dev] bug in tm module?

Henning Westerholt hw at gilawa.com
Thu Mar 24 08:04:28 CET 2022


please do not post the same message several times. 😊

As mentioned in the other e-mail, please create a new issue in the tracker (link in the previous e-mail from me) for this. Then it can be further analysed there.



Henning Westerholt – https://skalatan.de/blog/
Kamailio services – https://gilawa.com<https://gilawa.com/>

From: sr-dev <sr-dev-bounces at lists.kamailio.org> On Behalf Of dpaape at frontier.com
Sent: Wednesday, March 23, 2022 4:33 PM
To: sr-dev at lists.kamailio.org
Subject: [sr-dev] bug in tm module?

 I'm running K5.5.3 and have checked the 'issues' link in github and saw nothing regarding what I am seeing.  I think that there is a bug in the tm module with respect to the "tm:local-response" event route.  In the "t_reply.c" file, there is a static variable called '_tm_local_response_set_lookup'.  This variable is initialized at load time to zero.  It is checked in the '_reply_light()' routine and will initiate a local callback from the config script if "armed".  The problem as I see it is that if the callback is readied, the variable is set to one.  But it is never reset.
So the practical outworking is as follows.  A register is received and the request_route arms the callback.  The register requires an authorization (local database sqlite).  After the 401 is sent back, the callback via the module event route is called as expected.  All good except that the module event route script fragment is never executed again after the first call.
I'm no expert on the tm module but I would think that somewhere in there, the variable should be reset to zero so that subsequent transactions can initiate the event route again.

thanks for any help,

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.kamailio.org/pipermail/sr-dev/attachments/20220324/4467fc78/attachment.htm>

More information about the sr-dev mailing list