aboutsummaryrefslogtreecommitdiff
path: root/src/script.h
diff options
context:
space:
mode:
authorPieter Wuille <pieter.wuille@gmail.com>2013-04-30 21:56:04 +0200
committerPieter Wuille <sipa@ulyssis.org>2013-05-30 05:18:42 +0200
commit5d891489ab7828ad8db15e85bb63e2f13f021a6a (patch)
tree24cd213e276977570de5b299872368bdf70ac929 /src/script.h
parentec0004aca0a2bf11f99c9587ddb2bf8ea818d3bb (diff)
Make CPubKey statically allocated
Diffstat (limited to 'src/script.h')
-rw-r--r--src/script.h6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/script.h b/src/script.h
index 4b29f6273c..e639003549 100644
--- a/src/script.h
+++ b/src/script.h
@@ -348,8 +348,10 @@ public:
CScript& operator<<(const CPubKey& key)
{
- std::vector<unsigned char> vchKey = key.Raw();
- return (*this) << vchKey;
+ assert(key.size() < OP_PUSHDATA1);
+ insert(end(), (unsigned char)key.size());
+ insert(end(), key.begin(), key.end());
+ return *this;
}
CScript& operator<<(const CBigNum& b)