<p>George Joseph has uploaded this change for <strong>review</strong>.</p><p><a href="https://gerrit.asterisk.org/8660">View Change</a></p><pre style="font-family: monospace,monospace; white-space: pre-wrap;">pjroject_bundled:  Add already-destroyed check to tsx_timer_callback<br><br>There have been cases that when the transaction timer callback is called<br>the tsx is already destroyed.  This causes a crash.  We now check the<br>tsx state and return if the tsx is already destroyed.<br><br>Change-Id: If93acd5e48d9ca5bb553f2405d5afc836842fe1c<br>---<br>A third-party/pjproject/patches/0090-sip_transaction-In-tsx_timer_callback-check-if-tsx-i.patch<br>1 file changed, 31 insertions(+), 0 deletions(-)<br><br></pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;">git pull ssh://gerrit.asterisk.org:29418/asterisk refs/changes/60/8660/1</pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;">diff --git a/third-party/pjproject/patches/0090-sip_transaction-In-tsx_timer_callback-check-if-tsx-i.patch b/third-party/pjproject/patches/0090-sip_transaction-In-tsx_timer_callback-check-if-tsx-i.patch<br>new file mode 100644<br>index 0000000..12df346<br>--- /dev/null<br>+++ b/third-party/pjproject/patches/0090-sip_transaction-In-tsx_timer_callback-check-if-tsx-i.patch<br>@@ -0,0 +1,31 @@<br>+From beaa7874ff8e3b1d2951218c94e7e6bbba9c0531 Mon Sep 17 00:00:00 2001<br>+From: George Joseph <gjoseph@digium.com><br>+Date: Sun, 25 Mar 2018 12:30:05 -0600<br>+Subject: [PATCH] sip_transaction: In tsx_timer_callback, check if tsx is<br>+ already gone<br>+<br>+There have been cases that when the transaction timer callback is called<br>+the tsx is already destroyed.  This causes a crash.  We now check the<br>+tsx state and return if the tsx is already destroyed.<br>+---<br>+ pjsip/src/pjsip/sip_transaction.c | 4 ++++<br>+ 1 file changed, 4 insertions(+)<br>+<br>+diff --git a/pjsip/src/pjsip/sip_transaction.c b/pjsip/src/pjsip/sip_transaction.c<br>+index d52b12a72..6d4cdc65f 100644<br>+--- a/pjsip/src/pjsip/sip_transaction.c<br>++++ b/pjsip/src/pjsip/sip_transaction.c<br>+@@ -1119,6 +1119,10 @@ static void tsx_timer_callback( pj_timer_heap_t *theap, pj_timer_entry *entry)<br>+ <br>+     PJ_UNUSED_ARG(theap);<br>+ <br>++    if (tsx->state >= PJSIP_TSX_STATE_DESTROYED) {<br>++        return;<br>++    }<br>++<br>+     if (entry->id == TRANSPORT_ERR_TIMER) {<br>+         /* Posted transport error event */<br>+   entry->id = 0;<br>+-- <br>+2.14.3<br>+<br></pre><p>To view, visit <a href="https://gerrit.asterisk.org/8660">change 8660</a>. To unsubscribe, visit <a href="https://gerrit.asterisk.org/settings">settings</a>.</p><div itemscope itemtype="http://schema.org/EmailMessage"><div itemscope itemprop="action" itemtype="http://schema.org/ViewAction"><link itemprop="url" href="https://gerrit.asterisk.org/8660"/><meta itemprop="name" content="View Change"/></div></div>

<div style="display:none"> Gerrit-Project: asterisk </div>
<div style="display:none"> Gerrit-Branch: 13 </div>
<div style="display:none"> Gerrit-MessageType: newchange </div>
<div style="display:none"> Gerrit-Change-Id: If93acd5e48d9ca5bb553f2405d5afc836842fe1c </div>
<div style="display:none"> Gerrit-Change-Number: 8660 </div>
<div style="display:none"> Gerrit-PatchSet: 1 </div>
<div style="display:none"> Gerrit-Owner: George Joseph <gjoseph@digium.com> </div>