Funwayguy / StandardQuestingPack

MIT License
16 stars 19 forks source link

(1.12) Memory Leak: PlayerContainerListener#LISTEN_MAP #108

Open Meldexun opened 2 years ago

Meldexun commented 2 years ago

The PlayerContainerListener#LISTEN_MAP map will be populated whenever a player joins a world server side. The problem is that the map never gets cleared.

When joining a singleplayer world and then joining a server afterwards the map will still contain an entry. And this means the player object of the singleplayer world and the world object will remain in memory.

Another problem can happen on dedicated servers. When joining a server, going to the nether and then leaving the server will cause the player object with the nether world to be loaded in memory.