News:

SimuTranslator
Make Simutrans speak your language.

Fix network chat bug

Started by Ashley, March 30, 2012, 12:03:31 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Ashley

Ok so this is my bug, and my fix. I found that the server could get into an infinite loop of sending chat messages to itself since the check for whether a chat message was from itself or not didn't work. The new way this is done is much simpler, avoid the check entirely and don't send messages from the server to itself (calling the add_message() function directly).

This patch can be applied to r5583 (112.2.2 stable) while maintaining compatibility with clients, so you can fix servers to run on this stable.
Use Firefox? Interested in IPv6? Try SixOrNot the IPv6 status indicator for Firefox.
Why not try playing Simutrans online? See the Game Servers board for details.