SteamWar/BauSystem
Archiviert
13
0

Hotfix BauSystem RamUsage and AutoShutdown

Dieser Commit ist enthalten in:
yoyosource 2021-04-03 08:33:34 +02:00
Ursprung 08e0578fb4
Commit 829e3c64f0

Datei anzeigen

@ -34,7 +34,7 @@ public class RamUsage {
try {
long memorySize = ((com.sun.management.OperatingSystemMXBean) ManagementFactory.getOperatingSystemMXBean()).getTotalPhysicalMemorySize();
long freeMemory = ((com.sun.management.OperatingSystemMXBean) ManagementFactory.getOperatingSystemMXBean()).getFreePhysicalMemorySize();
System.out.println((memorySize - freeMemory) / (double) memorySize);
System.out.println(memorySize + " " + freeMemory);
return (memorySize - freeMemory) / (double) memorySize;
} catch (Throwable throwable) {
throwable.printStackTrace();