Index: channels/chan_sip.c =================================================================== RCS file: /usr/cvsroot/asterisk/channels/chan_sip.c,v retrieving revision 1.677 diff -u -r1.677 chan_sip.c --- channels/chan_sip.c 17 Mar 2005 23:03:07 -0000 1.677 +++ channels/chan_sip.c 18 Mar 2005 20:21:57 -0000 @@ -1932,6 +1932,8 @@ if (!p->pendinginvite) { /* Send a hangup */ transmit_request_with_auth(p, SIP_BYE, 0, 1, 1); + ast_clear_flag(&locflags, SIP_NEEDDESTROY); + sip_scheddestroy(p, 15000); } else { /* Note we will need a BYE when this all settles out but we can't send one while we have "INVITE" outstanding. */