<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/3160/">https://reviewboard.asterisk.org/r/3160/</a>
</td>
</tr>
</table>
<br />
<blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: 10px;">
<p style="margin-top: 0;">On January 28th, 2014, 5:37 p.m. CST, <b>Jonathan Rose</b> wrote:</p>
<blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: 10px;">
<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">So one quick question comes to mind... Why does pickupchan simply scan by uniqueid if a channel couldn't be found while chanspy has to supply an argument to decide on the behavior?</pre>
</blockquote>
</blockquote>
<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">The parameter to PickupChan is supposed to be a single channel name. The fallback to searching by uniqueid is possible since we are still looking for a single channel.
The chanprefix parameter to ChanSpy is supposed to be the channel technology such as "SIP", "DAHDI", or "Agent" so you will get a group of channels to iterate over and the first matching channel is initially spied upon. Dialed digits are applied to the chanprefix to make a channel name so you can jump to a specific channel. So if chanprefix is "SIP" then dialed digits are appended to generate SIP/200. You could supply SIP/200 and just be able to monitor SIP/200 but the code doesn't disable the channel generation code for dialed digits. The new 'u' option disables that code as it makes no sense for "/200" to be appended to a uniqueid.</pre>
<br />
<p>- rmudgett</p>
<br />
<p>On January 27th, 2014, 3:11 p.m. CST, rmudgett 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.ab6f3b1072c9.png'); background-position: left top; background-repeat: repeat-x; border: 1px black solid;">
<tr>
<td>
<div>Review request for Asterisk Developers.</div>
<div>By rmudgett.</div>
<p style="color: grey;"><i>Updated Jan. 27, 2014, 3:11 p.m.</i></p>
<div style="margin-top: 1.5em;">
<b style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Bugs: </b>
<a href="https://issues.asterisk.org/jira/browse/AFS-42">AFS-42</a>
</div>
<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;">ChanSpy now accepts a channel uniqueid or a fully specified channel name as the chanprefix parameter if the 'u' option is specified.
</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;">Requested to spy on a channel using a fully specified channel name and also by uniqueid.
Spying is successful if the channel exists.
Spying fails if the channel does not exist.</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/app_chanspy.c <span style="color: grey">(406647)</span></li>
<li>/trunk/CHANGES <span style="color: grey">(406647)</span></li>
</ul>
<p><a href="https://reviewboard.asterisk.org/r/3160/diff/" style="margin-left: 3em;">View Diff</a></p>
</td>
</tr>
</table>
</div>
</body>
</html>