diff options
author | Pieter Wuille <pieter.wuille@gmail.com> | 2018-04-25 16:49:39 -0700 |
---|---|---|
committer | MeshCollider <dobsonsa68@gmail.com> | 2020-07-15 15:29:22 +1200 |
commit | e629d07199b83f4ad313b23a94c9016e3276c52a (patch) | |
tree | d7773f538f49e4f08dbeab7d04968f738ade12c9 /src/script/sign.cpp | |
parent | f4de89edfa8be4501534fec0c662c650a4ce7ef2 (diff) | |
download | bitcoin-e629d07199b83f4ad313b23a94c9016e3276c52a.tar.xz |
Do not turn OP_1NEGATE in scriptSig into 0x0181 in signing code
Co-authored-by: Samuel Dobson <dobsonsa68@gmail.com>
Diffstat (limited to 'src/script/sign.cpp')
-rw-r--r-- | src/script/sign.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/script/sign.cpp b/src/script/sign.cpp index f425215549..9b3f94f14d 100644 --- a/src/script/sign.cpp +++ b/src/script/sign.cpp @@ -186,6 +186,8 @@ static CScript PushAll(const std::vector<valtype>& values) result << OP_0; } else if (v.size() == 1 && v[0] >= 1 && v[0] <= 16) { result << CScript::EncodeOP_N(v[0]); + } else if (v.size() == 1 && v[0] == 0x81) { + result << OP_1NEGATE; } else { result << v; } |