aboutsummaryrefslogtreecommitdiffstats
path: root/main/asterisk.c
diff options
context:
space:
mode:
authorbbryant <bbryant@f38db490-d61c-443f-a65b-d21fe96a405b>2008-07-16 21:26:13 +0000
committerbbryant <bbryant@f38db490-d61c-443f-a65b-d21fe96a405b>2008-07-16 21:26:13 +0000
commit6789e473de6acaa7e0102efe0781753cd79213f5 (patch)
treef3209d141f9bf7091a5fed4b65f70e778900236f /main/asterisk.c
parent989babae94868b048f68ac14d50c04b05c168814 (diff)
Merged revisions 131445 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk ........ r131445 | bbryant | 2008-07-16 16:24:18 -0500 (Wed, 16 Jul 2008) | 9 lines Fixes an issue with "core show sysinfo" that used the wrong operator to calculate the number of bytes from a sysinfo structure. unsigned long. (closes issue #13057) Reported by: eliel Patches: asterisk.c.patch uploaded by eliel (license 64) ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.0@131455 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'main/asterisk.c')
-rw-r--r--main/asterisk.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/main/asterisk.c b/main/asterisk.c
index 80102120f..1f45b86bc 100644
--- a/main/asterisk.c
+++ b/main/asterisk.c
@@ -502,11 +502,11 @@ static char *handle_show_sysinfo(struct ast_cli_entry *e, int cmd, struct ast_cl
ast_cli(a->fd, "\nSystem Statistics\n");
ast_cli(a->fd, "-----------------\n");
ast_cli(a->fd, " System Uptime: %ld hours\n", sys_info.uptime/3600);
- ast_cli(a->fd, " Total RAM: %ld KiB\n", (sys_info.totalram / sys_info.mem_unit)/1024);
- ast_cli(a->fd, " Free RAM: %ld KiB\n", (sys_info.freeram / sys_info.mem_unit)/1024);
- ast_cli(a->fd, " Buffer RAM: %ld KiB\n", (sys_info.bufferram / sys_info.mem_unit)/1024);
- ast_cli(a->fd, " Total Swap Space: %ld KiB\n", (sys_info.totalswap / sys_info.mem_unit)/1024);
- ast_cli(a->fd, " Free Swap Space: %ld KiB\n\n", (sys_info.freeswap / sys_info.mem_unit)/1024);
+ ast_cli(a->fd, " Total RAM: %ld KiB\n", (sys_info.totalram * sys_info.mem_unit)/1024);
+ ast_cli(a->fd, " Free RAM: %ld KiB\n", (sys_info.freeram * sys_info.mem_unit)/1024);
+ ast_cli(a->fd, " Buffer RAM: %ld KiB\n", (sys_info.bufferram * sys_info.mem_unit)/1024);
+ ast_cli(a->fd, " Total Swap Space: %ld KiB\n", (sys_info.totalswap * sys_info.mem_unit)/1024);
+ ast_cli(a->fd, " Free Swap Space: %ld KiB\n\n", (sys_info.freeswap * sys_info.mem_unit)/1024);
ast_cli(a->fd, " Number of Processes: %d \n\n", sys_info.procs);
return CLI_SUCCESS;
}