<p> Attention is currently required from: N A. </p>
<p><a href="https://gerrit.asterisk.org/c/asterisk/+/17655">View Change</a></p><p>8 comments:</p><ul style="list-style: none; padding: 0;"><li style="margin: 0; padding: 0;"><p><a href="null">File funcs/func_groupcount.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/+/17655/comment/dec3fb5d_53ed767a">Patch Set #21, Line 1186:</a> <code style="font-family:monospace,monospace"> buf[1] = '\0';</code></p><p><blockquote style="border-left: 1px solid #aaa; margin: 10px 0; padding: 0 10px;">whitespace issue</blockquote></p><p style="white-space: pre-wrap; word-wrap: break-word;">Done</p></li><li style="margin: 0; padding: 0 0 0 16px;"><p style="margin-bottom: 4px;"><a href="https://gerrit.asterisk.org/c/asterisk/+/17655/comment/9ffede78_0c2d488a">Patch Set #21, Line 1253:</a> <code style="font-family:monospace,monospace"> snprintf(groups_ret, sizeof(groups_ret), "%d", groups);</code></p><p><blockquote style="border-left: 1px solid #aaa; margin: 10px 0; padding: 0 10px;">Couldn't you just snprintf into buf directly? Why the intermediate buffer?</blockquote></p><p style="white-space: pre-wrap; word-wrap: break-word;">Done</p></li><li style="margin: 0; padding: 0 0 0 16px;"><p style="margin-bottom: 4px;"><a href="https://gerrit.asterisk.org/c/asterisk/+/17655/comment/48c8cfa0_3d6e0dd3">Patch Set #21, Line 1419:</a> <code style="font-family:monospace,monospace"> return 0;</code></p><p><blockquote style="border-left: 1px solid #aaa; margin: 10px 0; padding: 0 10px;">This should return -1</blockquote></p><p style="white-space: pre-wrap; word-wrap: break-word;">Done</p></li></ul></li><li style="margin: 0; padding: 0;"><p><a href="null">File main/app.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/+/17655/comment/89b53946_327b6439">Patch Set #21, Line 2423:</a> <code style="font-family:monospace,monospace">int ast_app_group_set_var(struct ast_channel *chan, const char *group, const char *category, const char *name, const char *value) {</code></p><p><blockquote style="border-left: 1px solid #aaa; margin: 10px 0; padding: 0 10px;">Opening brace should be on a separate line</blockquote></p><p style="white-space: pre-wrap; word-wrap: break-word;">Done</p></li><li style="margin: 0; padding: 0 0 0 16px;"><p style="margin-bottom: 4px;"><a href="https://gerrit.asterisk.org/c/asterisk/+/17655/comment/7f613986_ed119f9e">Patch Set #21, Line 2431:</a> <code style="font-family:monospace,monospace"> return 0;</code></p><p><blockquote style="border-left: 1px solid #aaa; margin: 10px 0; padding: 0 10px;">I see in the documentation we return 0 on failure and 1 on success, but why is that?</blockquote></p><p style="white-space: pre-wrap; word-wrap: break-word;">Fixed to be normalized with standard asterisk fn returns</p></li><li style="margin: 0; padding: 0 0 0 16px;"><p style="margin-bottom: 4px;"><a href="https://gerrit.asterisk.org/c/asterisk/+/17655/comment/b5aa5168_dcc067f6">Patch Set #21, Line 2444:</a> <code style="font-family:monospace,monospace"> AST_RWLIST_TRAVERSE_SAFE_BEGIN(&groups_meta, gmi, group_meta_list) {</code></p><p><blockquote style="border-left: 1px solid #aaa; margin: 10px 0; padding: 0 10px;">!= 0 is unnecessary here</blockquote></p><p style="white-space: pre-wrap; word-wrap: break-word;">Same this as below... being explicit about what we're looking for.</p><p style="white-space: pre-wrap; word-wrap: break-word;">Certainly this can be changed if it bugs you that much!</p></li><li style="margin: 0; padding: 0 0 0 16px;"><p style="margin-bottom: 4px;"><a href="https://gerrit.asterisk.org/c/asterisk/+/17655/comment/eef22b61_226a7691">Patch Set #21, Line 2479:</a> <code style="font-family:monospace,monospace"> if (newvariable == NULL) {</code></p><blockquote style="border-left: 1px solid #aaa; margin: 10px 0; padding: 0 10px;"><p style="white-space: pre-wrap; word-wrap: break-word;">Could just do !newvariable</p></blockquote><p style="white-space: pre-wrap; word-wrap: break-word;">I kind of remember being told the opposite (regarding coding standards for Asterisk... to be more explicit about compariters and not to rely on default behaviors of !</p></li><li style="margin: 0; padding: 0 0 0 16px;"><p style="margin-bottom: 4px;"><a href="https://gerrit.asterisk.org/c/asterisk/+/17655/comment/915730a8_eaaf4ac2">Patch Set #21, Line 2854:</a> <code style="font-family:monospace,monospace">int ast_app_group_meta_wrlock(void)</code></p><blockquote style="border-left: 1px solid #aaa; margin: 10px 0; padding: 0 10px;"><p style="white-space: pre-wrap; word-wrap: break-word;">I must be missing something, but why are these functions here? I see them in the header file, and here, why are they needed?</p></blockquote><p style="white-space: pre-wrap; word-wrap: break-word;">It's for allowing direct access to the groups/meta list in func_groupcount. The others that aren't used currently were added for consistency.</p></li></ul></li></ul><p>To view, visit <a href="https://gerrit.asterisk.org/c/asterisk/+/17655">change 17655</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/+/17655"/><meta itemprop="name" content="View Change"/></div></div>
<div style="display:none"> Gerrit-Project: asterisk </div>
<div style="display:none"> Gerrit-Branch: 18 </div>
<div style="display:none"> Gerrit-Change-Id: I23e48d1cdfc8adaffdfec2e936e56143603914f2 </div>
<div style="display:none"> Gerrit-Change-Number: 17655 </div>
<div style="display:none"> Gerrit-PatchSet: 21 </div>
<div style="display:none"> Gerrit-Owner: Mark Murawski <markm@intellasoft.net> </div>
<div style="display:none"> Gerrit-Reviewer: Friendly Automation </div>
<div style="display:none"> Gerrit-Reviewer: N A <asterisk@phreaknet.org> </div>
<div style="display:none"> Gerrit-Reviewer: Sean Bright <sean@seanbright.com> </div>
<div style="display:none"> Gerrit-CC: George Joseph <gjoseph@digium.com> </div>
<div style="display:none"> Gerrit-Attention: N A <asterisk@phreaknet.org> </div>
<div style="display:none"> Gerrit-Comment-Date: Sat, 14 Jan 2023 21:04:32 +0000 </div>
<div style="display:none"> Gerrit-HasComments: Yes </div>
<div style="display:none"> Gerrit-Has-Labels: No </div>
<div style="display:none"> Comment-In-Reply-To: N A <asterisk@phreaknet.org> </div>
<div style="display:none"> Gerrit-MessageType: comment </div>