[Libreoffice-commits] online.git: Branch 'distro/collabora/collabora-online-cd' - wsd/Admin.cpp
Pranav Kant
pranavk at collabora.co.uk
Tue Jul 11 13:24:42 UTC 2017
wsd/Admin.cpp | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
New commits:
commit 60da8087810e349ed3185e9b4bf46219ab3685fe
Author: Pranav Kant <pranavk at collabora.co.uk>
Date: Tue Jul 11 17:48:21 2017 +0530
This is percentage of total sys memory, not total consumed memory
Change-Id: I16b8b3d217cd0fabed83a9c63a5966cc6fe4d8fb
(cherry picked from commit ccce64eeeffce4ebef4f3cf7bde6ab288c6a1989)
Reviewed-on: https://gerrit.libreoffice.org/39817
Reviewed-by: Andras Timar <andras.timar at collabora.com>
Tested-by: Andras Timar <andras.timar at collabora.com>
diff --git a/wsd/Admin.cpp b/wsd/Admin.cpp
index 08d3916f..1e811dca 100644
--- a/wsd/Admin.cpp
+++ b/wsd/Admin.cpp
@@ -444,7 +444,7 @@ void Admin::triggerMemoryCleanup(size_t totalMem)
float memToFreePercentage = 0;
if ( (memToFreePercentage = (totalMem/static_cast<double>(_totalSysMem)) - memLimit/100.) > 0.0 )
{
- int memToFree = memToFreePercentage * totalMem;
+ int memToFree = memToFreePercentage * _totalSysMem;
LOG_TRC("Memory to be freed (in kB) : " << memToFree);
// prepare document list sorted by most idle times
std::list<DocBasicInfo> docList = _model.getDocumentsSortedByIdle();
More information about the Libreoffice-commits
mailing list