From 6c3a7808db2ba7d3699aaa4c813da4eea810e577 Mon Sep 17 00:00:00 2001 From: Paul Nettle Date: Mon, 2 Oct 2017 11:02:09 -0500 Subject: Improved threading support, cleaner initialization process and added the ability to wait for threaded responses from HCI commands. --- src/HciSocket.h | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src/HciSocket.h') diff --git a/src/HciSocket.h b/src/HciSocket.h index 20dbe4e..b9eebb9 100644 --- a/src/HciSocket.h +++ b/src/HciSocket.h @@ -80,12 +80,18 @@ public: private: + // Wait for data to arrive, or for a shutdown event + // + // Returns true if data is available, false if we are shutting down + bool waitForDataOrShutdown() const; + // Utilitarian function for logging errors for the given operation void logErrno(const char *pOperation) const; int fdSocket; const size_t kResponseMaxSize = 64 * 1024; + const int kDataWaitTimeMS = 10; }; }; // namespace ggk \ No newline at end of file -- cgit v1.2.3