<html>
 <body>
  <div style="font-family: Verdana, Arial, Helvetica, Sans-Serif;">
   <table bgcolor="#f9f3c9" width="100%" cellpadding="8" style="border: 1px #c9c399 solid;">
    <tr>
     <td>
      This is an automatically generated e-mail. To reply, visit:
      <a href="https://reviewboard.asterisk.org/r/2361/">https://reviewboard.asterisk.org/r/2361/</a>
     </td>
    </tr>
   </table>
   <br />











<div>




<table width="100%" border="0" bgcolor="white" style="border: 1px solid #C0C0C0; border-collapse: collapse; margin: 2px padding: 2px;">
 <thead>
  <tr>
   <th colspan="4" bgcolor="#F0F0F0" style="border-bottom: 1px solid #C0C0C0; font-size: 9pt; padding: 4px 8px; text-align: left;">
    <a href="https://reviewboard.asterisk.org/r/2361/diff/9/?file=35480#file35480line98" style="color: black; font-weight: bold; text-decoration: underline;">/trunk/res/res_stasis_websocket.c</a>
    <span style="font-weight: normal;">

     (Diff revision 9)

    </span>
   </th>
  </tr>
 </thead>



 
 

 <tbody>

  <tr>
    <th bgcolor="#b1ebb0" style="border-right: 1px solid #C0C0C0;" align="right"><font size="2"></font></th>
    <td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "></pre></td>
    <th bgcolor="#b1ebb0" style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" align="right"><font size="2">98</font></th>
    <td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "><span class="tb">        </span><span class="tb">        </span><span class="k">return</span> <span class="n">CMP_MATCH</span> <span class="o">|</span> <span class="n">CMP_STOP</span><span class="p">;</span></pre></td>
  </tr>

 </tbody>

</table>

<pre style="margin-left: 2em; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">Should this really have CMP_STOP?</pre>
</div>
<br />

<div>




<table width="100%" border="0" bgcolor="white" style="border: 1px solid #C0C0C0; border-collapse: collapse; margin: 2px padding: 2px;">
 <thead>
  <tr>
   <th colspan="4" bgcolor="#F0F0F0" style="border-bottom: 1px solid #C0C0C0; font-size: 9pt; padding: 4px 8px; text-align: left;">
    <a href="https://reviewboard.asterisk.org/r/2361/diff/9/?file=35480#file35480line132" style="color: black; font-weight: bold; text-decoration: underline;">/trunk/res/res_stasis_websocket.c</a>
    <span style="font-weight: normal;">

     (Diff revision 9)

    </span>
   </th>
  </tr>
 </thead>



 
 

 <tbody>

  <tr>
    <th bgcolor="#b1ebb0" style="border-right: 1px solid #C0C0C0;" align="right"><font size="2"></font></th>
    <td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "></pre></td>
    <th bgcolor="#b1ebb0" style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" align="right"><font size="2">132</font></th>
    <td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "><span class="tb">        </span><span class="n">session</span><span class="o">-&gt;</span><span class="n">websocket_apps</span> <span class="o">=</span></pre></td>
  </tr>

  <tr>
    <th bgcolor="#b1ebb0" style="border-right: 1px solid #C0C0C0;" align="right"><font size="2"></font></th>
    <td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "></pre></td>
    <th bgcolor="#b1ebb0" style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" align="right"><font size="2">133</font></th>
    <td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "><span class="tb">        </span><span class="tb">        </span><span class="n">ao2_container_alloc</span><span class="p">(</span><span class="n">APPS_NUM_BUCKETS</span><span class="p">,</span> <span class="n">hash_app</span><span class="p">,</span> <span class="n">compare_app</span><span class="p">);</span></pre></td>
  </tr>

 </tbody>

</table>

<pre style="margin-left: 2em; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">Since having a container of strings seems to be popular lately and that&#39;s all websocket_apps is actually being used for, maybe pulling in ast_str_container_alloc from stasis-channel_events-take2 or stasis-bridge_events would be helpful.</pre>
</div>
<br />

<div>




<table width="100%" border="0" bgcolor="white" style="border: 1px solid #C0C0C0; border-collapse: collapse; margin: 2px padding: 2px;">
 <thead>
  <tr>
   <th colspan="4" bgcolor="#F0F0F0" style="border-bottom: 1px solid #C0C0C0; font-size: 9pt; padding: 4px 8px; text-align: left;">
    <a href="https://reviewboard.asterisk.org/r/2361/diff/9/?file=35480#file35480line147" style="color: black; font-weight: bold; text-decoration: underline;">/trunk/res/res_stasis_websocket.c</a>
    <span style="font-weight: normal;">

     (Diff revision 9)

    </span>
   </th>
  </tr>
 </thead>



 
 

 <tbody>

  <tr>
    <th bgcolor="#b1ebb0" style="border-right: 1px solid #C0C0C0;" align="right"><font size="2"></font></th>
    <td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "></pre></td>
    <th bgcolor="#b1ebb0" style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" align="right"><font size="2">147</font></th>
    <td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "><span class="k">static</span> <span class="kt">void</span> <span class="nf">session_shutdown</span><span class="p">(</span><span class="k">struct</span> <span class="n">stasis_ws_session_info</span> <span class="o">*</span><span class="n">session</span><span class="p">)</span></pre></td>
  </tr>

 </tbody>

</table>

<pre style="margin-left: 2em; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">Why is this not in the destructor code for stasis_ws_session_info?</pre>
</div>
<br />



<p>- opticron</p>


<br />
<p>On April 5th, 2013, 11:32 a.m. CDT, David Lee wrote:</p>








<table bgcolor="#fefadf" width="100%" cellspacing="0" cellpadding="8" style="background-image: url('https://reviewboard.asterisk.org/static/rb/images/review_request_box_top_bg.png'); background-position: left top; background-repeat: repeat-x; border: 1px black solid;">
 <tr>
  <td>

<div>Review request for Asterisk Developers.</div>
<div>By David Lee.</div>


<p style="color: grey;"><i>Updated April 5, 2013, 11:32 a.m.</i></p>









<div style="margin-top: 1.5em;">
 <b style="color: #575012; font-size: 10pt;">Repository: </b>
Asterisk
</div>


<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Description </h1>
 <table width="100%" bgcolor="#ffffff" cellspacing="0" cellpadding="10" style="border: 1px solid #b8b5a0">
 <tr>
  <td>
   <pre style="margin: 0; padding: 0; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">This patch is based on the stasis-core message bus, in
https://reviewboard.asterisk.org/r/2339/

This is the API that binds the Stasis dialplan application to external
Stasis applications. It also adds the beginnings of WebSocket
application support.

This module registers a dialplan function named Stasis, which is used
to put a channel into the named Stasis app. As a channel enters and
leaves the Stasis diaplan applcation, the Stasis app receives a
&#39;stasis-start&#39; and &#39;stasis-end&#39; events.

Stasis apps register themselves using the stasis_app_register and
stasis_app_unregister functions. Messages are sent to an appliction
using stasis_app_send.

Finally, Stasis apps control channels through the use of the
stasis_app_control object, and the family of stasis_app_control_*
functions.

The biggest unknown I have about this patch is how I&#39;m exporting
symbols from app_stasis.so. I believe I&#39;m doing it correctly, and they
should not need to use optional API. If anyone knows if it will be a
problem on BSD, Solaris, etc., please let me know.

Other changes along for the ride are:
 * An ast_frame_dtor function that&#39;s RAII_VAR safe
 * Some common JSON encoders for name/number, timeval, and
   context/extension/priority
</pre>
  </td>
 </tr>
</table>


<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Testing </h1>
<table width="100%" bgcolor="#ffffff" cellspacing="0" cellpadding="10" style="border: 1px solid #b8b5a0">
 <tr>
  <td>
   <pre style="margin: 0; padding: 0; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">Unit tests; ran a few channels through the applications</pre>
  </td>
 </tr>
</table>


<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Diffs</b> </h1>
<ul style="margin-left: 3em; padding-left: 0;">

 <li>/trunk/apps/Makefile <span style="color: grey">(384490)</span></li>

 <li>/trunk/apps/app_stasis.c <span style="color: grey">(PRE-CREATION)</span></li>

 <li>/trunk/apps/app_stasis.exports.in <span style="color: grey">(PRE-CREATION)</span></li>

 <li>/trunk/apps/stasis_json.c <span style="color: grey">(PRE-CREATION)</span></li>

 <li>/trunk/include/asterisk/app_stasis.h <span style="color: grey">(PRE-CREATION)</span></li>

 <li>/trunk/include/asterisk/frame.h <span style="color: grey">(384490)</span></li>

 <li>/trunk/include/asterisk/json.h <span style="color: grey">(384490)</span></li>

 <li>/trunk/include/asterisk/localtime.h <span style="color: grey">(384490)</span></li>

 <li>/trunk/main/frame.c <span style="color: grey">(384490)</span></li>

 <li>/trunk/main/json.c <span style="color: grey">(384490)</span></li>

 <li>/trunk/res/res_stasis_websocket.c <span style="color: grey">(PRE-CREATION)</span></li>

 <li>/trunk/tests/test_abstract_jb.c <span style="color: grey">(384490)</span></li>

 <li>/trunk/tests/test_app_stasis.c <span style="color: grey">(PRE-CREATION)</span></li>

 <li>/trunk/tests/test_json.c <span style="color: grey">(384490)</span></li>

</ul>

<p><a href="https://reviewboard.asterisk.org/r/2361/diff/" style="margin-left: 3em;">View Diff</a></p>







  </td>
 </tr>
</table>








  </div>
 </body>
</html>