aboutsummaryrefslogtreecommitdiff
path: root/src/keystore.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/keystore.cpp')
-rw-r--r--src/keystore.cpp12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/keystore.cpp b/src/keystore.cpp
index 594e0c61da..2a4c88d565 100644
--- a/src/keystore.cpp
+++ b/src/keystore.cpp
@@ -59,3 +59,15 @@ bool CBasicKeyStore::GetCScript(const CScriptID &hash, CScript& redeemScriptOut)
return false;
}
+bool CBasicKeyStore::AddWatchOnly(const CScript &dest)
+{
+ LOCK(cs_KeyStore);
+ setWatchOnly.insert(dest);
+ return true;
+}
+
+bool CBasicKeyStore::HaveWatchOnly(const CScript &dest) const
+{
+ LOCK(cs_KeyStore);
+ return setWatchOnly.count(dest) > 0;
+}