Conversation
Fixed a bug with players crashing when kicked. Thanks to https://github.com/Novaenia for the tip
|
You need to send world_stop packet before the kick |
I tracked through tracemalloc that the link still remains, and when using opensb, each player's entry increases the memory by 58-60 megabytes. If the player exits, the memory is not cleared and increases each time. Such a small fix now really does not allow the memory to increase by 50-60 MB, but only by 200-300 KB
|
Also, I tracked through tracemalloc that the link still remains, and when using opensb, each player's entry increases the memory by 58-60 megabytes. If the player exits, the memory is not cleared and increases each time. Such a small fix now really does not allow the memory to increase by 50-60 MB, but only by 200-300 KB Here is log when i joined game two times Here is second After fix: second rejoin: |
|
Ah, wait, for somehow it fixed crash for one time. Need more time to debug this |
|
Ok, found the reasoin why game is getting crash |
|
Great, now I definitely fixed the kick. I stop the writer after the player kick process starts. The sequence must be like this. world_stop packet, then server_disconnect packet |
Fixed a bug with players crashing when kicked. Thanks to https://github.com/Novaenia for the tip