From ae138566a94ed407c71dbc7a155c810b2389cc4b Mon Sep 17 00:00:00 2001 From: Adam Ierymenko Date: Fri, 1 Nov 2013 12:38:38 -0400 Subject: Updater code, work in progress... --- node/RuntimeEnvironment.hpp | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) (limited to 'node/RuntimeEnvironment.hpp') diff --git a/node/RuntimeEnvironment.hpp b/node/RuntimeEnvironment.hpp index 3d73ca56..4baaab6b 100644 --- a/node/RuntimeEnvironment.hpp +++ b/node/RuntimeEnvironment.hpp @@ -46,6 +46,7 @@ class CMWC4096; class Service; class Node; class Multicaster; +class Updater; /** * Holds global state for an instance of ZeroTier::Node @@ -71,24 +72,29 @@ public: demarc((Demarc *)0), topology((Topology *)0), sysEnv((SysEnv *)0), - nc((NodeConfig *)0) + nc((NodeConfig *)0), + updater((Updater *)0) #ifndef __WINDOWS__ ,netconfService((Service *)0) #endif { } + // home of saved state, identity, etc. std::string homePath; - // signal() to prematurely interrupt main loop wait + // signal() to prematurely interrupt main loop wait to cause loop to run + // again and detect some kind of change, exit, etc. Condition mainLoopWaitCondition; Identity identity; + // hacky... want to get rid of this flag... volatile bool shutdownInProgress; // Order matters a bit here. These are constructed in this order - // and then deleted in the opposite order on Node exit. + // and then deleted in the opposite order on Node exit. The order ensures + // that things that are needed are there before they're needed. Logger *log; // may be null CMWC4096 *prng; @@ -99,6 +105,7 @@ public: SysEnv *sysEnv; NodeConfig *nc; Node *node; + Updater *updater; // may be null if updates are disabled #ifndef __WINDOWS__ Service *netconfService; // may be null #endif -- cgit v1.2.3