From 681b9a640594907c822fabfc673424a2096792f1 Mon Sep 17 00:00:00 2001 From: Kim Alvefur Date: Tue, 25 Apr 2017 00:14:19 +0200 Subject: mod_admin_telnet: Output human-friendly memory usage when meminfo is unavailable (thanks nbastin) --- plugins/mod_admin_telnet.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/mod_admin_telnet.lua b/plugins/mod_admin_telnet.lua index 04e93d7e..293f6320 100644 --- a/plugins/mod_admin_telnet.lua +++ b/plugins/mod_admin_telnet.lua @@ -325,7 +325,7 @@ end function def_env.server:memory() if not has_pposix or not pposix.meminfo then - return true, "Lua is using "..collectgarbage("count"); + return true, "Lua is using "..human(collectgarbage("count")); end local mem, lua_mem = pposix.meminfo(), collectgarbage("count"); local print = self.session.print; -- cgit v1.2.3