summaryrefslogtreecommitdiff
path: root/plexgdm.h
diff options
context:
space:
mode:
authorchriszero <zerov83@gmail.com>2015-02-13 14:42:35 +0100
committerchriszero <zerov83@gmail.com>2015-02-13 14:42:35 +0100
commitb5c156939ddf2fc4ec3fa27ae1c3daae28681c12 (patch)
tree964a10beb9c142bd0378cc02b8ef0d473f59d5f2 /plexgdm.h
parent2ee181403f1c332ee34f658916035524e766cd7b (diff)
downloadvdr-plugin-plex-b5c156939ddf2fc4ec3fa27ae1c3daae28681c12.tar.gz
vdr-plugin-plex-b5c156939ddf2fc4ec3fa27ae1c3daae28681c12.tar.bz2
Fixes segfault if there was no network connection.
Discovers servers continuously every 30 seconds.
Diffstat (limited to 'plexgdm.h')
-rw-r--r--plexgdm.h12
1 files changed, 8 insertions, 4 deletions
diff --git a/plexgdm.h b/plexgdm.h
index 8cbedea..8aa8ad4 100644
--- a/plexgdm.h
+++ b/plexgdm.h
@@ -15,6 +15,7 @@
#include <Poco/Format.h>
#include <vdr/thread.h>
+#include <vdr/tools.h>
#include "PlexServer.h"
@@ -32,11 +33,11 @@ public:
void clientDetails(std::string c_id, std::string c_name, std::string c_port, std::string c_product, std::string c_version);
std::string getClientDetails();
PlexServer* getServerList();
- void discover();;
+ void discover();
void checkClientRegistration();
-
+
void Action(void);
-
+
//void startAll();
void startRegistration();
@@ -50,10 +51,13 @@ public:
protected:
- private:
+private:
plexgdm();
cMutex m_mutex;
cCondVar m_waitCondition;
+ int _discoverInterval;
+ cTimeMs _discoverTimer;
+ bool _helloSent;
Poco::Net::SocketAddress m_discoverAdress;
Poco::Net::SocketAddress m_clientRegisterGroup;