summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlexander Harkness <bearbin@gmail.com>2014-01-01 10:22:24 +0100
committerAlexander Harkness <bearbin@gmail.com>2014-01-01 10:22:24 +0100
commiteeeb2a6d223bbd560de5b83a86cf2faa98e1c02c (patch)
tree8201b06b2ccdb98bfc0c1f56ae75ae1915ecdc81
parentMerge pull request #480 from mc-server/CmakeNonMixed (diff)
parentFixed GetPhysicalRAMUsage on Linux (diff)
downloadcuberite-eeeb2a6d223bbd560de5b83a86cf2faa98e1c02c.tar
cuberite-eeeb2a6d223bbd560de5b83a86cf2faa98e1c02c.tar.gz
cuberite-eeeb2a6d223bbd560de5b83a86cf2faa98e1c02c.tar.bz2
cuberite-eeeb2a6d223bbd560de5b83a86cf2faa98e1c02c.tar.lz
cuberite-eeeb2a6d223bbd560de5b83a86cf2faa98e1c02c.tar.xz
cuberite-eeeb2a6d223bbd560de5b83a86cf2faa98e1c02c.tar.zst
cuberite-eeeb2a6d223bbd560de5b83a86cf2faa98e1c02c.zip
Diffstat (limited to '')
-rw-r--r--src/Root.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/Root.cpp b/src/Root.cpp
index 16a521698..fa1fdb37a 100644
--- a/src/Root.cpp
+++ b/src/Root.cpp
@@ -701,9 +701,9 @@ int cRoot::GetPhysicalRAMUsage(void)
{
AString Line;
std::getline(StatFile, Line);
- if (strncmp(Line.c_str(), "VmRSS:", 7) == 0)
+ if (strncmp(Line.c_str(), "VmRSS:", 6) == 0)
{
- int res = atoi(Line.c_str() + 8);
+ int res = atoi(Line.c_str() + 7);
return (res == 0) ? -1 : res; // If parsing failed, return -1
}
}