Make CKey::Load references const
No change in behavior, this just prevents CKey::Load arguments from looking like outputs.
This commit is contained in:
parent
b5e4b9b510
commit
04ededf001
2 changed files with 2 additions and 2 deletions
|
@ -233,7 +233,7 @@ bool CKey::SignCompact(const uint256 &hash, std::vector<unsigned char>& vchSig)
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
bool CKey::Load(CPrivKey &privkey, CPubKey &vchPubKey, bool fSkipCheck=false) {
|
bool CKey::Load(const CPrivKey &privkey, const CPubKey &vchPubKey, bool fSkipCheck=false) {
|
||||||
if (!ec_privkey_import_der(secp256k1_context_sign, (unsigned char*)begin(), privkey.data(), privkey.size()))
|
if (!ec_privkey_import_der(secp256k1_context_sign, (unsigned char*)begin(), privkey.data(), privkey.size()))
|
||||||
return false;
|
return false;
|
||||||
fCompressed = vchPubKey.IsCompressed();
|
fCompressed = vchPubKey.IsCompressed();
|
||||||
|
|
|
@ -135,7 +135,7 @@ public:
|
||||||
bool VerifyPubKey(const CPubKey& vchPubKey) const;
|
bool VerifyPubKey(const CPubKey& vchPubKey) const;
|
||||||
|
|
||||||
//! Load private key and check that public key matches.
|
//! Load private key and check that public key matches.
|
||||||
bool Load(CPrivKey& privkey, CPubKey& vchPubKey, bool fSkipCheck);
|
bool Load(const CPrivKey& privkey, const CPubKey& vchPubKey, bool fSkipCheck);
|
||||||
};
|
};
|
||||||
|
|
||||||
struct CExtKey {
|
struct CExtKey {
|
||||||
|
|
Loading…
Add table
Reference in a new issue