<p>Sean Bright has uploaded this change for <strong>review</strong>.</p><p><a href="https://gerrit.asterisk.org/c/asterisk/+/13504">View Change</a></p><pre style="font-family: monospace,monospace; white-space: pre-wrap;">db: Initialize condition primitive before use<br><br>The db_init() function ultimately calls db_sync() which signals the<br>condition before it is initialized.<br><br>Change-Id: Id4a4e025b637bc4ac7d90557fcb71d56598892ab<br>---<br>M main/db.c<br>1 file changed, 2 insertions(+), 1 deletion(-)<br><br></pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;">git pull ssh://gerrit.asterisk.org:29418/asterisk refs/changes/04/13504/1</pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;"><span>diff --git a/main/db.c b/main/db.c</span><br><span>index 4d1b372..193bd2e 100644</span><br><span>--- a/main/db.c</span><br><span>+++ b/main/db.c</span><br><span>@@ -1083,11 +1083,12 @@</span><br><span> </span><br><span> int astdb_init(void)</span><br><span> {</span><br><span style="color: hsl(120, 100%, 40%);">+ ast_cond_init(&dbcond, NULL);</span><br><span style="color: hsl(120, 100%, 40%);">+</span><br><span> if (db_init()) {</span><br><span> return -1;</span><br><span> }</span><br><span> </span><br><span style="color: hsl(0, 100%, 40%);">- ast_cond_init(&dbcond, NULL);</span><br><span> if (ast_pthread_create_background(&syncthread, NULL, db_sync_thread, NULL)) {</span><br><span> return -1;</span><br><span> }</span><br><span></span><br></pre><p>To view, visit <a href="https://gerrit.asterisk.org/c/asterisk/+/13504">change 13504</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/+/13504"/><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: Id4a4e025b637bc4ac7d90557fcb71d56598892ab </div>
<div style="display:none"> Gerrit-Change-Number: 13504 </div>
<div style="display:none"> Gerrit-PatchSet: 1 </div>
<div style="display:none"> Gerrit-Owner: Sean Bright <sean.bright@gmail.com> </div>
<div style="display:none"> Gerrit-MessageType: newchange </div>