aboutsummaryrefslogtreecommitdiff
path: root/src/script/script.h
diff options
context:
space:
mode:
authorGregory Sanders <gsanders87@gmail.com>2019-05-31 10:01:15 -0400
committerGregory Sanders <gsanders87@gmail.com>2019-06-13 09:27:14 -0400
commite1a55690e66ca962179bc8170695b92af8a3caa8 (patch)
treec1541588ea72b1b24a538b902cc59b46637beda0 /src/script/script.h
parentc7cfd20a77ce57d200b3b9e5e0dfb0d63818abdc (diff)
Delete error-prone CScript constructor
Diffstat (limited to 'src/script/script.h')
-rw-r--r--src/script/script.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/script/script.h b/src/script/script.h
index 11e8661a5b..6355b8a704 100644
--- a/src/script/script.h
+++ b/src/script/script.h
@@ -437,7 +437,9 @@ public:
explicit CScript(opcodetype b) { operator<<(b); }
explicit CScript(const CScriptNum& b) { operator<<(b); }
- explicit CScript(const std::vector<unsigned char>& b) { operator<<(b); }
+ // delete non-existent constructor to defend against future introduction
+ // e.g. via prevector
+ explicit CScript(const std::vector<unsigned char>& b) = delete;
CScript& operator<<(int64_t b) { return push_int64(b); }