1
0
mirror of https://github.com/luanti-org/luanti.git synced 2025-10-20 11:35:21 +02:00

Fix for being unable to connect to localhost rather than 127.0.0.1 (issue #210)

This commit is contained in:
Sascha Heylik
2012-08-18 15:51:42 +02:00
parent b717b6505b
commit aa5bf48bd9

View File

@@ -704,7 +704,12 @@ void GUIMainMenu::readInput(MainMenuData *dst)
{
gui::IGUIElement *e = getElementFromId(GUI_ID_ADDRESS_INPUT);
if(e != NULL)
dst->address = e->getText();
if (e->getText() == std::wstring(L"localhost")) {
dst->address = std::wstring(L"127.0.0.1");
}
else {
dst->address = e->getText();
}
}
{
gui::IGUIElement *e = getElementFromId(GUI_ID_PORT_INPUT);