<p>Corey Farrell has uploaded this change for <strong>review</strong>.</p><p><a href="https://gerrit.asterisk.org/7675">View Change</a></p><pre style="font-family: monospace,monospace; white-space: pre-wrap;">core: Fix unused variable error in handle_show_sysinfo.<br><br>Apparently in OSX it's possible for OSX to HAVE_SYSCTL but not<br>HAVE_SYSINFO or HAVE_SWAPCTL.  In this case freeswap caused an unused<br>variable error.<br><br>ASTERISK-26563 #close<br><br>Change-Id: I8ec5b1897b786cc1abaf62264aa75039eea05510<br>---<br>M main/asterisk.c<br>1 file changed, 3 insertions(+), 1 deletion(-)<br><br></pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;">git pull ssh://gerrit.asterisk.org:29418/asterisk refs/changes/75/7675/1</pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;">diff --git a/main/asterisk.c b/main/asterisk.c<br>index f8e31d5..01107e2 100644<br>--- a/main/asterisk.c<br>+++ b/main/asterisk.c<br>@@ -795,7 +795,9 @@<br> static char *handle_show_sysinfo(struct ast_cli_entry *e, int cmd, struct ast_cli_args *a)<br> {<br>    uint64_t physmem, freeram;<br>+#if defined(HAVE_SYSINFO) || defined(HAVE_SWAPCTL)<br>       uint64_t freeswap = 0;<br>+#endif<br>       int nprocs = 0;<br>       long uptime = 0;<br>      int totalswap = 0;<br>@@ -885,7 +887,7 @@<br> #if defined(HAVE_SYSINFO)<br>   ast_cli(a->fd, "  Buffer RAM:                %" PRIu64 " KiB\n", ((uint64_t) sys_info.bufferram * sys_info.mem_unit) / 1024);<br> #endif<br>-#if defined(HAVE_SWAPCTL) || defined(HAVE_SYSINFO)<br>+#if defined(HAVE_SYSINFO) || defined(HAVE_SWAPCTL)<br>       ast_cli(a->fd, "  Total Swap Space:          %d KiB\n", totalswap);<br>      ast_cli(a->fd, "  Free Swap Space:           %" PRIu64 " KiB\n\n", freeswap);<br> #endif<br></pre><p>To view, visit <a href="https://gerrit.asterisk.org/7675">change 7675</a>. To unsubscribe, 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/7675"/><meta itemprop="name" content="View Change"/></div></div>

<div style="display:none"> Gerrit-Project: asterisk </div>
<div style="display:none"> Gerrit-Branch: 13 </div>
<div style="display:none"> Gerrit-MessageType: newchange </div>
<div style="display:none"> Gerrit-Change-Id: I8ec5b1897b786cc1abaf62264aa75039eea05510 </div>
<div style="display:none"> Gerrit-Change-Number: 7675 </div>
<div style="display:none"> Gerrit-PatchSet: 1 </div>
<div style="display:none"> Gerrit-Owner: Corey Farrell <git@cfware.com> </div>