<p> Attention is currently required from: N A. </p>
<p>N A <strong>uploaded patch set #4</strong> to this change.</p><p><a href="https://gerrit.asterisk.org/c/asterisk/+/18004">View Change</a></p><pre style="font-family: monospace,monospace; white-space: pre-wrap;">cli: Fix CLI blocking forever on terminating backslash<br><br>A corner case exists in CLI parsing where if<br>a CLI user in a remote console ends with<br>a backslash and then invokes command completion<br>(using TAB or ?), then the console will freeze<br>forever until a SIGQUIT signal is sent to the<br>process, due to getting blocked forever<br>reading the command completion. CTRL+C<br>and other key combinations have no impact on<br>the CLI session.<br><br>This occurs because, in such cases, the CLI<br>process is waiting for AST_CLI_COMPLETE_EOF<br>to appear in the buffer from the main process,<br>but instead the main process is confused by<br>the funny syntax and thus prints out the CLI help.<br>As a result, the CLI process is stuck on the<br>read call, waiting for the completion that<br>will never come.<br><br>This prevents blocking forever by checking<br>if the data from the main process starts with<br>"Usage:". If it does, that means that CLI help<br>was sent instead of the tab complete vector,<br>and thus the CLI should bail out and not wait<br>any longer.<br><br>ASTERISK-29822 #close<br><br>Change-Id: I9810ac59304fec162da701653c9c834f0ec8f670<br>---<br>M main/asterisk.c<br>1 file changed, 17 insertions(+), 0 deletions(-)<br><br></pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;">git pull ssh://gerrit.asterisk.org:29418/asterisk refs/changes/04/18004/4</pre><p>To view, visit <a href="https://gerrit.asterisk.org/c/asterisk/+/18004">change 18004</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/+/18004"/><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: I9810ac59304fec162da701653c9c834f0ec8f670 </div>
<div style="display:none"> Gerrit-Change-Number: 18004 </div>
<div style="display:none"> Gerrit-PatchSet: 4 </div>
<div style="display:none"> Gerrit-Owner: N A <mail@interlinked.x10host.com> </div>
<div style="display:none"> Gerrit-Reviewer: Friendly Automation </div>
<div style="display:none"> Gerrit-Reviewer: Kevin Harwell <kharwell@digium.com> </div>
<div style="display:none"> Gerrit-Attention: N A <mail@interlinked.x10host.com> </div>
<div style="display:none"> Gerrit-MessageType: newpatchset </div>