<p>Kevin Harwell has uploaded this change for <strong>review</strong>.</p><p><a href="https://gerrit.asterisk.org/c/asterisk/+/13841">View Change</a></p><pre style="font-family: monospace,monospace; white-space: pre-wrap;">format_cap: make function parameters 'const'<br><br>There were a couple places where the format cap function parameter was not<br>'const' when it should have been. This patch makes them 'const'.<br><br>Change-Id: Ife753fb16a962d842a6b44f45363a61a66bfdb2e<br>---<br>M include/asterisk/format_cap.h<br>M main/format_cap.c<br>2 files changed, 4 insertions(+), 4 deletions(-)<br><br></pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;">git pull ssh://gerrit.asterisk.org:29418/asterisk refs/changes/41/13841/1</pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;"><span>diff --git a/include/asterisk/format_cap.h b/include/asterisk/format_cap.h</span><br><span>index 8b69e08..37021eb 100644</span><br><span>--- a/include/asterisk/format_cap.h</span><br><span>+++ b/include/asterisk/format_cap.h</span><br><span>@@ -308,7 +308,7 @@</span><br><span>  *</span><br><span>  * \return The contents of the buffer in \c buf</span><br><span>  */</span><br><span style="color: hsl(0, 100%, 40%);">-const char *ast_format_cap_get_names(struct ast_format_cap *cap, struct ast_str **buf);</span><br><span style="color: hsl(120, 100%, 40%);">+const char *ast_format_cap_get_names(const struct ast_format_cap *cap, struct ast_str **buf);</span><br><span> </span><br><span> #ifndef AST_FORMAT_CAP_NAMES_LEN</span><br><span> /*! Buffer size for callers of ast_format_cap_get_names to allocate. */</span><br><span>@@ -322,6 +322,6 @@</span><br><span>  * \retval 1 The format cap has zero formats or only ast_format_none</span><br><span>  * \retval 0 The format cap has at least one format</span><br><span>  */</span><br><span style="color: hsl(0, 100%, 40%);">-int ast_format_cap_empty(struct ast_format_cap *cap);</span><br><span style="color: hsl(120, 100%, 40%);">+int ast_format_cap_empty(const struct ast_format_cap *cap);</span><br><span> </span><br><span> #endif /* _AST_FORMAT_CAP_H */</span><br><span>diff --git a/main/format_cap.c b/main/format_cap.c</span><br><span>index d71ccdb..ca60557 100644</span><br><span>--- a/main/format_cap.c</span><br><span>+++ b/main/format_cap.c</span><br><span>@@ -699,7 +699,7 @@</span><br><span>      return internal_format_cap_identical(cap2, cap1);</span><br><span> }</span><br><span> </span><br><span style="color: hsl(0, 100%, 40%);">-const char *ast_format_cap_get_names(struct ast_format_cap *cap, struct ast_str **buf)</span><br><span style="color: hsl(120, 100%, 40%);">+const char *ast_format_cap_get_names(const struct ast_format_cap *cap, struct ast_str **buf)</span><br><span> {</span><br><span>  int i;</span><br><span> </span><br><span>@@ -725,7 +725,7 @@</span><br><span>     return ast_str_buffer(*buf);</span><br><span> }</span><br><span> </span><br><span style="color: hsl(0, 100%, 40%);">-int ast_format_cap_empty(struct ast_format_cap *cap)</span><br><span style="color: hsl(120, 100%, 40%);">+int ast_format_cap_empty(const struct ast_format_cap *cap)</span><br><span> {</span><br><span>   int count = ast_format_cap_count(cap);</span><br><span> </span><br><span></span><br></pre><p>To view, visit <a href="https://gerrit.asterisk.org/c/asterisk/+/13841">change 13841</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/+/13841"/><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: Ife753fb16a962d842a6b44f45363a61a66bfdb2e </div>
<div style="display:none"> Gerrit-Change-Number: 13841 </div>
<div style="display:none"> Gerrit-PatchSet: 1 </div>
<div style="display:none"> Gerrit-Owner: Kevin Harwell <kharwell@digium.com> </div>
<div style="display:none"> Gerrit-MessageType: newchange </div>