aboutsummaryrefslogtreecommitdiff
path: root/src/scheduler.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/scheduler.cpp')
-rw-r--r--src/scheduler.cpp13
1 files changed, 9 insertions, 4 deletions
diff --git a/src/scheduler.cpp b/src/scheduler.cpp
index 4edb2c6d9b..a94f6b2a66 100644
--- a/src/scheduler.cpp
+++ b/src/scheduler.cpp
@@ -1,11 +1,11 @@
-// Copyright (c) 2015-2016 The Bitcoin Core developers
+// Copyright (c) 2015-2017 The Bitcoin Core developers
// Distributed under the MIT software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
-#include "scheduler.h"
+#include <scheduler.h>
-#include "random.h"
-#include "reverselock.h"
+#include <random.h>
+#include <reverselock.h>
#include <assert.h>
#include <boost/bind.hpp>
@@ -206,3 +206,8 @@ void SingleThreadedSchedulerClient::EmptyQueue() {
should_continue = !m_callbacks_pending.empty();
}
}
+
+size_t SingleThreadedSchedulerClient::CallbacksPending() {
+ LOCK(m_cs_callbacks_pending);
+ return m_callbacks_pending.size();
+}