diff options
| author | Pieter Wuille <[email protected]> | 2012-10-19 23:13:44 +0200 |
|---|---|---|
| committer | Pieter Wuille <[email protected]> | 2012-10-19 23:18:07 +0200 |
| commit | 8980a509240107730eae8b517d80b444d1e31ccd (patch) | |
| tree | f9e79d9357cc8171bab6314d14ef59ef3d3f2376 /src/script.cpp | |
| parent | Revert "Merge pull request #1931 from laanwj/2012_10_newicons" (diff) | |
| download | discoin-8980a509240107730eae8b517d80b444d1e31ccd.tar.xz discoin-8980a509240107730eae8b517d80b444d1e31ccd.zip | |
Use CHashWriter also in SignatureHash(), and for message signing
Diffstat (limited to 'src/script.cpp')
| -rw-r--r-- | src/script.cpp | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/script.cpp b/src/script.cpp index 4357a9a1b..e8dd93d08 100644 --- a/src/script.cpp +++ b/src/script.cpp @@ -1117,10 +1117,9 @@ uint256 SignatureHash(CScript scriptCode, const CTransaction& txTo, unsigned int } // Serialize and hash - CDataStream ss(SER_GETHASH, 0); - ss.reserve(10000); + CHashWriter ss(SER_GETHASH, 0); ss << txTmp << nHashType; - return Hash(ss.begin(), ss.end()); + return ss.GetHash(); } |