diff options
| author | Gregory Sanders <[email protected]> | 2019-05-31 10:01:15 -0400 |
|---|---|---|
| committer | Gregory Sanders <[email protected]> | 2019-06-13 09:27:14 -0400 |
| commit | e1a55690e66ca962179bc8170695b92af8a3caa8 (patch) | |
| tree | c1541588ea72b1b24a538b902cc59b46637beda0 /src/script/interpreter.cpp | |
| parent | Merge #16086: contrib: use newer config.guess & config.sub in install_db4.sh (diff) | |
| download | discoin-e1a55690e66ca962179bc8170695b92af8a3caa8.tar.xz discoin-e1a55690e66ca962179bc8170695b92af8a3caa8.zip | |
Delete error-prone CScript constructor
Diffstat (limited to 'src/script/interpreter.cpp')
| -rw-r--r-- | src/script/interpreter.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/script/interpreter.cpp b/src/script/interpreter.cpp index 95b25b491..f8701b6d0 100644 --- a/src/script/interpreter.cpp +++ b/src/script/interpreter.cpp @@ -926,7 +926,7 @@ bool EvalScript(std::vector<std::vector<unsigned char> >& stack, const CScript& // Drop the signature in pre-segwit scripts but not segwit scripts if (sigversion == SigVersion::BASE) { - int found = FindAndDelete(scriptCode, CScript(vchSig)); + int found = FindAndDelete(scriptCode, CScript() << vchSig); if (found > 0 && (flags & SCRIPT_VERIFY_CONST_SCRIPTCODE)) return set_error(serror, SCRIPT_ERR_SIG_FINDANDDELETE); } @@ -992,7 +992,7 @@ bool EvalScript(std::vector<std::vector<unsigned char> >& stack, const CScript& { valtype& vchSig = stacktop(-isig-k); if (sigversion == SigVersion::BASE) { - int found = FindAndDelete(scriptCode, CScript(vchSig)); + int found = FindAndDelete(scriptCode, CScript() << vchSig); if (found > 0 && (flags & SCRIPT_VERIFY_CONST_SCRIPTCODE)) return set_error(serror, SCRIPT_ERR_SIG_FINDANDDELETE); } |