With async_task_data() I got it working like this:
```
event_route [tcp:closed] { # Handle TCP connection close
# Delete possible leftover registration
if ($conid) {
async_task_data("clean_location", "$conid");
}
route [clean_location] {
sql_query_async("sip_proxy_cache", "DELETE FROM location WHERE server_id=0
AND connection_id=$async(data)");
}
--
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/3843#issuecomment-2098879746
You are receiving this because you are subscribed to this thread.
Message ID: <kamailio/kamailio/issues/3843/2098879...@github.com>
_______________________________________________
Kamailio (SER) - Development Mailing List
To unsubscribe send an email to sr-dev-le...@lists.kamailio.org