diff options
| author | Pieter Wuille <[email protected]> | 2012-02-19 09:22:11 -0800 |
|---|---|---|
| committer | Pieter Wuille <[email protected]> | 2012-02-19 09:22:11 -0800 |
| commit | e0b8d459b189ee2b7e95a47b217e4b02bfb523b3 (patch) | |
| tree | f3b5f41d9c7b9348b285f9c422fe630bd30ff7eb /src | |
| parent | Merge pull request #865 from sipa/del_pwalletdb (diff) | |
| parent | Workaround for BN_bn2mpi reading/writing out of bounds (diff) | |
| download | discoin-e0b8d459b189ee2b7e95a47b217e4b02bfb523b3.tar.xz discoin-e0b8d459b189ee2b7e95a47b217e4b02bfb523b3.zip | |
Merge pull request #863 from sipa/bn2mpifix
Workaround for BN_bn2mpi reading/writing out of bounds
Diffstat (limited to 'src')
| -rw-r--r-- | src/bignum.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/bignum.h b/src/bignum.h index 4143f6003..a750025f3 100644 --- a/src/bignum.h +++ b/src/bignum.h @@ -243,7 +243,7 @@ public: std::vector<unsigned char> getvch() const { unsigned int nSize = BN_bn2mpi(this, NULL); - if (nSize < 4) + if (nSize <= 4) return std::vector<unsigned char>(); std::vector<unsigned char> vch(nSize); BN_bn2mpi(this, &vch[0]); |