13
0
geforkt von Mirrors/Paper

Fixed memory leak Chunk Compression handling. Thanks Zeerix!

By: EvilSeph <evilseph@gmail.com>
Dieser Commit ist enthalten in:
CraftBukkit/Spigot 2011-08-27 00:49:35 -04:00
Ursprung d617037db6
Commit 2d1f91b750

Datei anzeigen

@ -98,7 +98,12 @@ public final class ChunkCompressionThread implements Runnable {
private void addToPlayerQueueSize(EntityPlayer player, int amount) {
synchronized (queueSizePerPlayer) {
Integer count = queueSizePerPlayer.get(player);
queueSizePerPlayer.put(player, (count == null ? 0 : count) + amount);
amount += (count == null) ? 0 : count;
if (amount == 0) {
queueSizePerPlayer.remove(player);
} else {
queueSizePerPlayer.put(player, amount);
}
}
}