<p>Patch set 2:<span style="border-radius: 3px; display: inline-block; margin: 0 2px; padding: 4px;background-color: #ffd4d4; color: #000000;">Code-Review -1</span></p><p><a href="https://gerrit.asterisk.org/c/asterisk/+/15940">View Change</a></p><p>3 comments:</p><ul style="list-style: none; padding: 0;"><li style="margin: 0; padding: 0;"><p><a href="https://gerrit.asterisk.org/c/asterisk/+/15940/2/apps/app_originate.c">File apps/app_originate.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/asterisk/+/15940/2/apps/app_originate.c@100">Patch Set #2, Line 100:</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;">                                     <argument name="var1" required="false" argsep="="><br>                                                <argument name="name" multiple="true" required="true" /><br>                                          <argument name="value" required="true" /><br>                                   </argument><br></pre></blockquote></p><p style="white-space: pre-wrap; word-wrap: break-word;">This XML results in something that looks like this "v([name[=...]=value])" which isn't what you want.  Take a look at the XML for the MSet() application which is in main/pbx_variables.c.  If you copy that and change "parameter" to "argument" you'll get something like "v(name1=value1[^name2=value2[^...]])"</p></li><li style="margin: 0; padding: 0 0 0 16px;"><p style="margin-bottom: 4px;"><a href="https://gerrit.asterisk.org/c/asterisk/+/15940/2/apps/app_originate.c@244">Patch Set #2, Line 244:</a> <code style="font-family:monospace,monospace">     </code></p><p style="white-space: pre-wrap; word-wrap: break-word;">Whitespace.</p></li><li style="margin: 0; padding: 0 0 0 16px;"><p style="margin-bottom: 4px;"><a href="https://gerrit.asterisk.org/c/asterisk/+/15940/2/apps/app_originate.c@252">Patch Set #2, Line 252:</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;">                    tmp = strchr(text, '='); /* use = sign to separate var value from name */<br>                     if (!tmp) {<br>                           ast_log(LOG_ERROR, "Variable syntax error: %s\n", tmp);<br>                             goto return_cleanup;<br>                  }<br>                     *tmp = '\0';<br>                  varname = text;<br>                       tmp = ast_skip_blanks(tmp + 1);<br>                       varvalue = tmp;<br>                       tmp = strchr(varvalue, '^'); /* start of the next variable, if there is one */<br>                        if (tmp) {<br>                            *tmp = '\0';<br>                          text = ast_skip_blanks(tmp + 1); /* for the next variable */<br>                  } else {<br>                              text = NULL; /* this was the last variable */<br>                 }<br></pre></blockquote></p><p style="white-space: pre-wrap; word-wrap: break-word;">Take a look at ast_strsep().  It does some of this work for you.  Also take a look at app.h.  There are helpers like ast_app_separate_args that can also do this.</p></li></ul></li></ul><p>To view, visit <a href="https://gerrit.asterisk.org/c/asterisk/+/15940">change 15940</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/+/15940"/><meta itemprop="name" content="View Change"/></div></div>

<div style="display:none"> Gerrit-Project: asterisk </div>
<div style="display:none"> Gerrit-Branch: 16 </div>
<div style="display:none"> Gerrit-Change-Id: Ia64cfe97d2792bcbf4775b3126cad662922a8b66 </div>
<div style="display:none"> Gerrit-Change-Number: 15940 </div>
<div style="display:none"> Gerrit-PatchSet: 2 </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: George Joseph <gjoseph@digium.com> </div>
<div style="display:none"> Gerrit-Comment-Date: Thu, 27 May 2021 13:39:53 +0000 </div>
<div style="display:none"> Gerrit-HasComments: Yes </div>
<div style="display:none"> Gerrit-Has-Labels: Yes </div>
<div style="display:none"> Gerrit-MessageType: comment </div>