diff options
author | glozow <gzhao408@berkeley.edu> | 2021-05-26 18:12:06 +0100 |
---|---|---|
committer | glozow <gzhao408@berkeley.edu> | 2021-06-02 09:40:39 +0100 |
commit | 7d91442461776e2ef240d7885f768b624de341a7 (patch) | |
tree | c4311c25f8f9e07fd8f3a9c894a01c0276c57a68 /src | |
parent | 6c5f19d9c4d267c54f4dbc4f9d65370ff1e0625b (diff) | |
download | bitcoin-7d91442461776e2ef240d7885f768b624de341a7.tar.xz |
[rpc] reserve space in txns
Diffstat (limited to 'src')
-rw-r--r-- | src/rpc/rawtransaction.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/rpc/rawtransaction.cpp b/src/rpc/rawtransaction.cpp index 339d711ac9..526d262dce 100644 --- a/src/rpc/rawtransaction.cpp +++ b/src/rpc/rawtransaction.cpp @@ -951,6 +951,7 @@ static RPCHelpMan testmempoolaccept() CFeeRate(AmountFromValue(request.params[1])); std::vector<CTransactionRef> txns; + txns.reserve(raw_transactions.size()); for (const auto& rawtx : raw_transactions.getValues()) { CMutableTransaction mtx; if (!DecodeHexTx(mtx, rawtx.get_str())) { |