Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
CompassService memory leak #1810
Yes, there should be a potential memory leak when worlds are unloaded as it does not clean up the reference to the world in this case.
"Temporarily" is probably caused as a server stop will explicitly free these references. "some" most likely due to not everyone enters a world with a compass, thus the reader for this world is never loaded.
I would appreciate, if you could point in some directions to verify it. Also to test a potential fix and not just hope it might work.
I unfortunately don't know any details as I've only stumbled across it through analyzing a heap dump after 1-2 days of uptime (FC2). I can only offer to install a new build and observe its behavior.
The finalizer of whatever holds the file descriptor should eventually close the file, which is of course no alternative to (also presumably) stopping the CompassService explicitly from the unload event.