mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-02-09 02:59:31 +08:00
refactor: [qt] Use SpanReader to avoid two vector copies
This commit is contained in:
@@ -189,8 +189,7 @@ void RecentRequestsTableModel::addNewRequest(const SendCoinsRecipient &recipient
|
||||
// called from ctor when loading from wallet
|
||||
void RecentRequestsTableModel::addNewRequest(const std::string &recipient)
|
||||
{
|
||||
std::vector<uint8_t> data(recipient.begin(), recipient.end());
|
||||
DataStream ss{data};
|
||||
SpanReader ss{MakeByteSpan(recipient)};
|
||||
|
||||
RecentRequestEntry entry;
|
||||
ss >> entry;
|
||||
|
||||
Reference in New Issue
Block a user