<p>Jaco Kroon has uploaded this change for <strong>review</strong>.</p><p><a href="https://gerrit.asterisk.org/c/asterisk/+/20039">View Change</a></p><pre style="font-family: monospace,monospace; white-space: pre-wrap;">app_queue: Fix ordering problem joining queue.<br><br>Introduced for ASTERISK-30437 - dereferencing qe->parent before it was<br>being properly set. This should now resolve that correctly.<br><br>Apologies for not testing the submission. Unfortunately I don't have a<br>dev host available right at the moment either and is under pressure to<br>finish other work prior to the end of the month.<br><br>Change-Id: I8047cfb1ccd006c10fdc288e12f85561b17baea0<br>Signed-off-by: Jaco Kroon <jaco@uls.co.za><br>---<br>M apps/app_queue.c<br>1 file changed, 22 insertions(+), 4 deletions(-)<br><br></pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;">git pull ssh://gerrit.asterisk.org:29418/asterisk refs/changes/39/20039/1</pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;"><span>diff --git a/apps/app_queue.c b/apps/app_queue.c</span><br><span>index d4362ae..a75857a 100644</span><br><span>--- a/apps/app_queue.c</span><br><span>+++ b/apps/app_queue.c</span><br><span>@@ -8523,10 +8523,6 @@</span><br><span> qe.last_pos_said = 0;</span><br><span> qe.last_pos = 0;</span><br><span> qe.last_periodic_announce_time = time(NULL);</span><br><span style="color: hsl(0, 100%, 40%);">- if (qe.parent->periodicannouncestartdelay >= 0) {</span><br><span style="color: hsl(0, 100%, 40%);">- qe.last_periodic_announce_time += qe.parent->periodicannouncestartdelay;</span><br><span style="color: hsl(0, 100%, 40%);">- qe.last_periodic_announce_time -= qe.parent->periodicannouncefrequency;</span><br><span style="color: hsl(0, 100%, 40%);">- }</span><br><span> qe.last_periodic_announce_sound = 0;</span><br><span> qe.valid_digits = 0;</span><br><span> if (join_queue(args.queuename, &qe, &reason, position)) {</span><br><span>@@ -8535,6 +8531,11 @@</span><br><span> return 0;</span><br><span> }</span><br><span> ast_assert(qe.parent != NULL);</span><br><span style="color: hsl(120, 100%, 40%);">+ </span><br><span style="color: hsl(120, 100%, 40%);">+ if (qe.parent->periodicannouncestartdelay >= 0) {</span><br><span style="color: hsl(120, 100%, 40%);">+ qe.last_periodic_announce_time += qe.parent->periodicannouncestartdelay;</span><br><span style="color: hsl(120, 100%, 40%);">+ qe.last_periodic_announce_time -= qe.parent->periodicannouncefrequency;</span><br><span style="color: hsl(120, 100%, 40%);">+ }</span><br><span> </span><br><span> ast_queue_log(args.queuename, ast_channel_uniqueid(chan), "NONE", "ENTERQUEUE", "%s|%s|%d",</span><br><span> S_OR(args.url, ""),</span><br><span></span><br></pre><p>To view, visit <a href="https://gerrit.asterisk.org/c/asterisk/+/20039">change 20039</a>. To unsubscribe, or for help writing mail filters, 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/c/asterisk/+/20039"/><meta itemprop="name" content="View Change"/></div></div>
<div style="display:none"> Gerrit-Project: asterisk </div>
<div style="display:none"> Gerrit-Branch: master </div>
<div style="display:none"> Gerrit-Change-Id: I8047cfb1ccd006c10fdc288e12f85561b17baea0 </div>
<div style="display:none"> Gerrit-Change-Number: 20039 </div>
<div style="display:none"> Gerrit-PatchSet: 1 </div>
<div style="display:none"> Gerrit-Owner: Jaco Kroon <jaco@uls.co.za> </div>
<div style="display:none"> Gerrit-MessageType: newchange </div>