glest / glest-source

Glest is a network multi-player cross-platform 3D real-time strategy (RTS) game, where you create armies of units and battle different factions.
https://glest.io
GNU General Public License v3.0
57 stars 39 forks source link

ZG incorrectly detects wrong router setup #189

Closed andy5995 closed 5 years ago

andy5995 commented 6 years ago

While testing, after successfully running a server several times within 10 minutes (not playing a game, but just running a server so I can connect to with a client locally), now ZG incorrectly detects a wrong router setup.

Trying to connect to '104.235.241.67' using port '61357'...
socket_connect() failed.
 Reason: (111) Connection refused
wrong router setup
*ERROR* [2018-07-11 13:03:46] In [menu_state_custom_game.cpp::simpleTaskForMasterServer Line 3869] error checking response from masterserver elapsed seconds = 9.00 / 15
Response:
Trying to connect to '104.235.241.67' using port '61357'...
socket_connect() failed.
 Reason: (111) Connection refused
wrong router setup

image

I don't know if the origin of this bug lies within the source code or the code from the master server.

I don't know how to reproduce it other than repeatedly running a server. (choosing custom game -> checking the box for "publish on master server"

andy5995 commented 6 years ago

I had to reboot to fix that.

It happened again afterward, after more testing. However, I found that when I switch to testing with a headless server, it doesn't reproduce. It's apparently only a problem if hosting via LAN Game or checking the box for "publish to master server" from the custom game set-up menu.

I'm on Debian 9 Linux, using the latest build.

andy5995 commented 6 years ago

One thing that seems to reproduce this rather frequently

Join lobby

click host game

click "scenario" box and switch to a scenario that has network slots and re-check "publish on master server" if it's become unchecked.