I'm just hosting a headless server on this system for Internet players since there are currently few servers available.
Nevertheless, I would like to be able to start another custom game at the same time, to test a few things. Ideally I could do so without having to change the game configuration.
However, if I start MegaGlest a second time and turn to the custom game menu, MegaGlest crashes immediately without any warning on the GUI with this:
megaglest v3.7.0
Compiled using: GNUC: 40702 [64bit] on: Nov 14 2012 21:22:16 platform: Linux-X64 endianness: little
SVN: [Rev: 3911] - using STREFLOP [SSE] - [no-denormals]
[2012-11-14 21:43:07] *ERROR* In [menu_state_custom_game.cpp::MenuStateCustomGame 139]
Network init error:
Error binding socket sock = 16, address [127.0.0.1] port = 61355 err = -1, error = (Error: 98 - [Address already in use])
Stack Trace:
./megaglest:Shared::Platform::megaglest_runtime_error::megaglest_runtime_error(std::string const&, bool)address [0x9b5502] line: 237
./megaglest:Shared::Platform::ServerSocket::bind(int)address [0x9d1ded] line: 2220
./megaglest:Shared::Platform::ServerSocket::listen(int)address [0x9d2007] line: 2247
./megaglest:Glest::Game::ServerInterface::ServerInterface(bool)address [0x7f1865] line: 88
./megaglest:Glest::Game::NetworkManager::init(Glest::Game::NetworkRole, bool)address [0x7d28d9] line: 53
./megaglest:Glest::Game::MenuStateCustomGame::MenuStateCustomGame(Glest::Game::Program*, Glest::Game::MainMenu*, bool, Glest::Game::ParentMenuState, bool, Glest::Game::GameSettings*, bool, std::string)address [0x7514ee] line: 147
./megaglest:Glest::Game::MenuStateNewGame::mouseClick(int, int, Shared::Platform::MouseButton)address [0x713fe9] line: 95
./megaglest:Glest::Game::MainWindow::eventMouseDown(int, int, Shared::Platform::MouseButton)address [0x64d23e] line: 624
./megaglest:Shared::Platform::Window::handleMouseDown(SDL_Event)address [0x9b06f1] line: 676
./megaglest:Shared::Platform::Window::handleEvent()address [0x9b18b5] line: 161
./megaglest:Glest::Game::glestMain(int, char**)address [0x6741f4] line: 4682
./megaglest:Glest::Game::glestMainWrapper(int, char**)address [0x67909b] line: 4949
/lib/x86_64-linux-gnu/libc.so.6:__libc_start_main()address [0x7fd8dc01676d] line: 0
./megaglest() [0x507289]address [0x507289]
megaglest: /home/tomreyn/SCM/megaglest-trunk/source/glest_game/network/network_manager.cpp:98: Glest::Game::ServerInterface* Glest::Game::NetworkManager::getServerInterface(bool): Assertion `gameNetworkInterface!=__null' failed.
This is not very user friendly, it would be nice to handle this situation by disabling network slots and displaying a message that network slots are unavailable because the gameserver port is in use. If this is hard to program, then maybe there could be a user friendly GUI message explaining why it's exiting there before the window closes.