diff options
author | Alexander Tkachev | 2016-07-20 15:55:30 +0600 |
---|---|---|
committer | Alexander Tkachev | 2016-08-24 16:07:55 +0600 |
commit | 39865e6e6cf67e3b5a3867540dde76969b244246 (patch) | |
tree | f0ae49a16f840c54087109175e6897393d484327 /backends/networking/sdl_net/localwebserver.h | |
parent | b1264df120b6594a79d99cbb1cc5ef944fa2e448 (diff) | |
download | scummvm-rg350-39865e6e6cf67e3b5a3867540dde76969b244246.tar.gz scummvm-rg350-39865e6e6cf67e3b5a3867540dde76969b244246.tar.bz2 scummvm-rg350-39865e6e6cf67e3b5a3867540dde76969b244246.zip |
CLOUD: Add port override for LocalWebserver
It's enabled only when NETWORKING_LOCALWEBSERVER_ENABLE_PORT_OVERRIDE is
defined.
It's not defined, because override means we have to reconfigure our
redirect links somehow to use the override port.
Diffstat (limited to 'backends/networking/sdl_net/localwebserver.h')
-rw-r--r-- | backends/networking/sdl_net/localwebserver.h | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/backends/networking/sdl_net/localwebserver.h b/backends/networking/sdl_net/localwebserver.h index 1185cda890..3512583605 100644 --- a/backends/networking/sdl_net/localwebserver.h +++ b/backends/networking/sdl_net/localwebserver.h @@ -50,7 +50,7 @@ namespace Networking { class LocalWebserver : public Common::Singleton<LocalWebserver> { static const uint32 FRAMES_PER_SECOND = 20; static const uint32 TIMER_INTERVAL = 1000000 / FRAMES_PER_SECOND; - static const uint32 SERVER_PORT = 12345; + static const uint32 DEFAULT_SERVER_PORT = 12345; static const uint32 MAX_CONNECTIONS = 10; friend void localWebserverTimer(void *); //calls handle() @@ -73,6 +73,7 @@ class LocalWebserver : public Common::Singleton<LocalWebserver> { uint32 _idlingFrames; Common::Mutex _handleMutex; Common::String _address; + uint32 _serverPort; void startTimer(int interval = TIMER_INTERVAL); void stopTimer(); @@ -95,6 +96,7 @@ public: Common::String getAddress(); IndexPageHandler &indexPageHandler(); bool isRunning(); + static uint32 getPort(); static void setClientGetHandler(Client &client, Common::String response, long code = 200, const char *mimeType = nullptr); static void setClientGetHandler(Client &client, Common::SeekableReadStream *responseStream, long code = 200, const char *mimeType = nullptr); |