<p style="white-space: pre-wrap; word-wrap: break-word;">My understanding (which could very well be incorrect) is that if you are protecting mutable state with a lock, you need to consistently use the same lock. Not -1ing, I just wanted it to be seen.</p><p><a href="https://gerrit.asterisk.org/c/asterisk/+/11179">View Change</a></p><p>2 comments:</p><ul style="list-style: none; padding: 0;"><li style="margin: 0; padding: 0;"><p><a href="https://gerrit.asterisk.org/#/c/11179/1/main/manager.c">File main/manager.c:</a></p><ul style="list-style: none; padding: 0;"><li style="margin: 0; padding: 0 0 0 16px;"><p style="margin-bottom: 4px;"><a href="https://gerrit.asterisk.org/#/c/11179/1/main/manager.c@4158">Patch Set #1, Line 4158:</a> </p><p><blockquote style="border-left: 1px solid #aaa; margin: 10px 0; padding: 0 10px;"><pre style="font-family: monospace,monospace; white-space: pre-wrap;"><br>  if (s->session->waiting_thread != AST_PTHREADT_NULL) {<br>          pthread_kill(s->session->waiting_thread, SIGURG);<br>       }<br></pre></blockquote></p><p style="white-space: pre-wrap; word-wrap: break-word;">waiting_thread isn't protected with notify_lock here</p></li><li style="margin: 0; padding: 0 0 0 16px;"><p style="margin-bottom: 4px;"><a href="https://gerrit.asterisk.org/#/c/11179/1/main/manager.c@7907">Patch Set #1, Line 7907:</a> </p><p><blockquote style="border-left: 1px solid #aaa; margin: 10px 0; padding: 0 10px;"><pre style="font-family: monospace,monospace; white-space: pre-wrap;"><br>                     if (session->waiting_thread != AST_PTHREADT_NULL) {<br>                                pthread_kill(session->waiting_thread, SIGURG);<br>                     }<br></pre></blockquote></p><p style="white-space: pre-wrap; word-wrap: break-word;">waiting_thread isn't protected with notify_lock here</p></li></ul></li></ul><p>To view, visit <a href="https://gerrit.asterisk.org/c/asterisk/+/11179">change 11179</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/+/11179"/><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-Change-Id: Ifbcac007faca9ad0231640f5e82a6ca9228f261b </div>
<div style="display:none"> Gerrit-Change-Number: 11179 </div>
<div style="display:none"> Gerrit-PatchSet: 1 </div>
<div style="display:none"> Gerrit-Owner: Joshua Colp <jcolp@digium.com> </div>
<div style="display:none"> Gerrit-Reviewer: Friendly Automation </div>
<div style="display:none"> Gerrit-Reviewer: Sean Bright <sean.bright@gmail.com> </div>
<div style="display:none"> Gerrit-Comment-Date: Tue, 26 Mar 2019 13:31:19 +0000 </div>
<div style="display:none"> Gerrit-HasComments: Yes </div>
<div style="display:none"> Gerrit-Has-Labels: No </div>
<div style="display:none"> Gerrit-MessageType: comment </div>