mirror of
https://github.com/PaperMC/Paper.git
synced 2025-01-25 01:25:03 +01:00
MC-100382: Fix Pathfinding Memory Leak
https://bugs.mojang.com/browse/MC-100382 A reference to a ChunkCache is never cleaned up after doing a pathfind operation, resulting in leaking chunks. The leaked chunks then hold references to other entities that may also be leaking ChunkCache's, creating a cascading problem. By: Aikar <aikar@aikar.co>
This commit is contained in:
parent
41e881d59f
commit
911f7f5cf7
1 changed files with 11 additions and 0 deletions
11
paper-server/nms-patches/PathfinderAbstract.patch
Normal file
11
paper-server/nms-patches/PathfinderAbstract.patch
Normal file
|
@ -0,0 +1,11 @@
|
||||||
|
--- a/net/minecraft/server/PathfinderAbstract.java
|
||||||
|
+++ b/net/minecraft/server/PathfinderAbstract.java
|
||||||
|
@@ -23,7 +23,7 @@
|
||||||
|
this.f = MathHelper.d(entityinsentient.width + 1.0F);
|
||||||
|
}
|
||||||
|
|
||||||
|
- public void a() {}
|
||||||
|
+ public void a() { this.a = (IBlockAccess) null; } // CraftBukkit - don't leak Chunk Cache
|
||||||
|
|
||||||
|
protected PathPoint a(int i, int j, int k) {
|
||||||
|
int l = PathPoint.b(i, j, k);
|
Loading…
Add table
Reference in a new issue