mirror of
https://github.com/YatopiaMC/Yatopia.git
synced 2024-11-25 20:16:09 +01:00
36030ef022
* Updated Upstream and Sidestream(s) (Paper/Tuinity/Purpur/Airplane/Empirecraft) Upstream/An Sidestream has released updates that appears to apply and compile correctly This update has NOT been tested by YatopiaMC and as with ANY update, please do your own testing. Paper Changes: 13a476e15 Deprecate PlayerLeaveBedEvent#setBedSpawn 3a1d95c71 [Auto] Updated Upstream (CraftBukkit) d4dcc1a2e Updated Upstream (CraftBukkit) e886d8118 Updated Upstream () 8bc0c6c31 Updated Upstream (CraftBukkit/Spigot) (#5169) 002f65b8b living entity allow attribute registration (#4723) 69a5c67b1 fix calling setSize on dead slimes causing invincibility (fixes #5137) (#5168) Tuinity Changes: 502d57b Updated Upstream (Paper) 87e0cd9 Print exceptions for light scheduling Purpur Changes: 7fc2d31 Updated Upstream (Paper & Tuinity) Airplane Changes: d7d1626 Remove multithreaded entity tracker 677ec73 Ensure armor change event is on main thread c07d254 Fix crash ec7605c Updated Upstream (Tuinity) 2768f39 Update DEAR commit message e975972 Multithreaded entity tracking 98244f9 Updated Upstream (Tuinity) 44b2499 Larger headings 2c4a7fb Merge pull request #6 from Encode42/master cc19631 More changes beba27a Badges and variables 0aeaf12 Improve readability, grammar, etc. Empirecraft Changes: bbc8d297 Updated Paper * Updated Upstream and Sidestream(s) (Paper/Origami) Upstream/An Sidestream has released updates that appears to apply and compile correctly This update has NOT been tested by YatopiaMC and as with ANY update, please do your own testing. Paper Changes: 3dadd97bb [CI-SKIP] [Meta] Exempt more labels from being marked as stale (#5142) 36a72cad3 [Auto] Updated Upstream (Bukkit/CraftBukkit/Spigot) Origami Changes: 168394a Access config after loading it... fixes velocity auto offline-mode c47b182 Add velocity to automatic offline mode
32 lines
1.6 KiB
Diff
32 lines
1.6 KiB
Diff
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
From: Ivan Pekov <ivan@mrivanplays.com>
|
|
Date: Thu, 10 Sep 2020 21:02:26 +0300
|
|
Subject: [PATCH] Fix LightEngineThreaded memory leak
|
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/LightEngineThreaded.java b/src/main/java/net/minecraft/server/LightEngineThreaded.java
|
|
index 001ac05cf26237eec8a77c476e678ff6d0840311..7b4935dd8c54f5fcb4f26b96c270d3e4102133a3 100644
|
|
--- a/src/main/java/net/minecraft/server/LightEngineThreaded.java
|
|
+++ b/src/main/java/net/minecraft/server/LightEngineThreaded.java
|
|
@@ -110,6 +110,8 @@ public class LightEngineThreaded extends LightEngine implements AutoCloseable {
|
|
}
|
|
}
|
|
|
|
+ public final void remove(long chunkId) { pendingTasks.removeIf(task -> task.chunkId == chunkId); queueUpdate(); } // Yatopia
|
|
+
|
|
public final boolean isEmpty() {
|
|
return this.size == 0 && this.pendingTasks.isEmpty();
|
|
}
|
|
diff --git a/src/main/java/net/minecraft/server/WorldServer.java b/src/main/java/net/minecraft/server/WorldServer.java
|
|
index 7fa720de5c24820d2cd7eea5f74d6c1502afe461..2734b76f58401bdddf6407db7c7c445d489ad488 100644
|
|
--- a/src/main/java/net/minecraft/server/WorldServer.java
|
|
+++ b/src/main/java/net/minecraft/server/WorldServer.java
|
|
@@ -1792,6 +1792,7 @@ public class WorldServer extends World implements GeneratorAccessSeed {
|
|
}
|
|
// Paper end
|
|
|
|
+ chunkProvider.getLightEngine().queue.remove(chunk.getPos().pair()); // Yatopia - unregister from light queue
|
|
}
|
|
|
|
public void unregisterEntity(Entity entity) {
|