diff options
author | Alexander Tkachev | 2016-07-20 13:20:23 +0600 |
---|---|---|
committer | Alexander Tkachev | 2016-08-24 16:07:55 +0600 |
commit | e833c8f65c05a1db182d4982d4e1b8edfe014980 (patch) | |
tree | e54d253b312d226aee77a96a62e467227c2fef4c | |
parent | 63311bac267ed0ebacc10068d8ffd2354a5f4371 (diff) | |
download | scummvm-rg350-e833c8f65c05a1db182d4982d4e1b8edfe014980.tar.gz scummvm-rg350-e833c8f65c05a1db182d4982d4e1b8edfe014980.tar.bz2 scummvm-rg350-e833c8f65c05a1db182d4982d4e1b8edfe014980.zip |
CLOUD: Add OSD warning when can't start LocalWebserver
-rw-r--r-- | backends/networking/sdl_net/localwebserver.cpp | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/backends/networking/sdl_net/localwebserver.cpp b/backends/networking/sdl_net/localwebserver.cpp index 29db0b71ff..1480418b70 100644 --- a/backends/networking/sdl_net/localwebserver.cpp +++ b/backends/networking/sdl_net/localwebserver.cpp @@ -28,6 +28,7 @@ #include "common/str.h" #include "common/system.h" #include "common/timer.h" +#include "common/translation.h" #include <SDL/SDL_net.h> #ifdef POSIX @@ -100,7 +101,11 @@ void LocalWebserver::start() { _serverSocket = SDLNet_TCP_Open(&ip); if (!_serverSocket) { - error("SDLNet_TCP_Open: %s\n", SDLNet_GetError()); + warning("SDLNet_TCP_Open: %s", SDLNet_GetError()); + stopTimer(); + g_system->displayMessageOnOSD(_("Failed to start local webserver.\nCheck whether selected port is not used by another application and try again.")); + _handleMutex.unlock(); + return; } // Create a socket set |