aboutsummaryrefslogtreecommitdiff
path: root/src/script
diff options
context:
space:
mode:
authorAndrew Chow <achow101-github@achow101.com>2020-07-27 15:19:17 -0400
committerAndrew Chow <github@achow101.com>2022-08-29 17:30:38 -0400
commit0b26e7cdf2659fd8b54d21fd2bd749f9f3e87af8 (patch)
tree8b29d28df07757076047617d5655b91b8928feda /src/script
parent31764c3f872f4f01b48d50585f86e97c41554954 (diff)
downloadbitcoin-0b26e7cdf2659fd8b54d21fd2bd749f9f3e87af8.tar.xz
descriptors: addr() and raw() should return false for ToPrivateString
They don't have any private data and they can't be nested so they should return false for ToPrivateString.
Diffstat (limited to 'src/script')
-rw-r--r--src/script/descriptor.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/script/descriptor.cpp b/src/script/descriptor.cpp
index 434e106dad..0078bb2a65 100644
--- a/src/script/descriptor.cpp
+++ b/src/script/descriptor.cpp
@@ -612,7 +612,7 @@ public:
return AddChecksum(ret);
}
- bool ToPrivateString(const SigningProvider& arg, std::string& out) const final
+ bool ToPrivateString(const SigningProvider& arg, std::string& out) const override
{
bool ret = ToStringHelper(&arg, out, StringType::PRIVATE);
out = AddChecksum(out);
@@ -698,6 +698,7 @@ public:
return OutputTypeFromDestination(m_destination);
}
bool IsSingleType() const final { return true; }
+ bool ToPrivateString(const SigningProvider& arg, std::string& out) const final { return false; }
};
/** A parsed raw(H) descriptor. */
@@ -718,6 +719,7 @@ public:
return OutputTypeFromDestination(dest);
}
bool IsSingleType() const final { return true; }
+ bool ToPrivateString(const SigningProvider& arg, std::string& out) const final { return false; }
};
/** A parsed pk(P) descriptor. */