IgorrG created an issue (kamailio/kamailio#4268)
### Description
We use RPC dlg.end_dlg command to terminate dialog. In most cases it does operate properly and send BYE from kamailio to both sides of dialog (as show on screenshot).

We found that in some cases we have only first BYE sent to calling party. Second BYE never sent, when called party tries to terminate call by timeout it get responded with 481.


In logs we have such warning:
мая 27 15:11:46 service-proxy.iqtek.ru kamailio[3518388]: 2(3518388) WARNING: {1 1 BYE 541d3f2c-43fd-43b6-af24-bad1fbf85eb6} dialog [dlg_handlers.c:1343]: dlg_onroute(): unable to find dialog for BYE with route param 'e1e.4f22' [3614:8948] and call-id '541d3f2c-43fd-43b6-af24-bad1fbf85eb6'
We also found that in this case this warning shown in logs 0.04 seconds after kamailio receive 200ok.
### Additional Information
* **Kamailio Version** - output of `kamailio -v`
``` # ./kamailio -V version: kamailio 5.8.6 (x86_64/linux) fb71db flags: USE_TCP, USE_TLS, USE_SCTP, TLS_HOOKS, USE_RAW_SOCKS, DISABLE_NAGLE, USE_MCAST, DNS_IP_HACK, SHM_MMAP, PKG_MALLOC, MEM_JOIN_FREE, Q_MALLOC, F_MALLOC, TLSF_MALLOC, DBG_SR_MEMORY, USE_FUTEX, FAST_LOCK-ADAPTIVE_WAIT, USE_DNS_CACHE, USE_DNS_FAILOVER, USE_NAPTR, USE_DST_BLOCKLIST, HAVE_RESOLV_RES, TLS_PTHREAD_MUTEX_SHARED ADAPTIVE_WAIT_LOOPS 1024, MAX_RECV_BUFFER_SIZE 262144, MAX_SEND_BUFFER_SIZE 262144, MAX_URI_SIZE 1024, BUF_SIZE 65535, DEFAULT PKG_SIZE 8MB poll method support: poll, epoll_lt, epoll_et, sigio_rt, select. id: fb71db compiled on 17:38:27 May 26 2025 with gcc 12.2.0
```
* **Operating System**:
``` # lsb_release -a No LSB modules are available. Distributor ID: Debian Description: Debian GNU/Linux 12 (bookworm) Release: 12 Codename: bookworm
# uname -a Linux rtp-kamailio2 6.1.0-32-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.1.129-1 (2025-03-06) x86_64 GNU/Linux
```