From a54c2b438c0abc574039055ecfc70dd829e2cade Mon Sep 17 00:00:00 2001 From: Adam Ierymenko Date: Thu, 15 Dec 2016 15:08:47 -0800 Subject: Basic support for streaming of changes via stdout from controller. --- controller/JSONDB.hpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'controller/JSONDB.hpp') diff --git a/controller/JSONDB.hpp b/controller/JSONDB.hpp index bd1ae5a5..40113655 100644 --- a/controller/JSONDB.hpp +++ b/controller/JSONDB.hpp @@ -19,6 +19,7 @@ #ifndef ZT_JSONDB_HPP #define ZT_JSONDB_HPP +#include #include #include @@ -41,7 +42,8 @@ namespace ZeroTier { class JSONDB { public: - JSONDB(const std::string &basePath) : + JSONDB(const std::string &basePath,FILE *feed) : + _feed(feed), _basePath(basePath) { _reload(_basePath); @@ -106,6 +108,7 @@ private: inline bool operator!=(const _E &e) const { return (obj != e.obj); } }; + FILE *_feed; std::string _basePath; std::map _db; }; -- cgit v1.2.3