Skip to content

Commit

Permalink
GH-3 Fix use of packed_transaction_ptr over shared_ptr<packed_transac…
Browse files Browse the repository at this point in the history
…tion>
  • Loading branch information
heifner committed Apr 12, 2024
1 parent a6e4de8 commit 382f648
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion plugins/net_plugin/net_plugin.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3189,7 +3189,8 @@ namespace eosio {
auto ds = pending_message_buffer.create_datastream();
unsigned_int which{};
fc::raw::unpack( ds, which );
packed_transaction_ptr ptr = std::make_shared<packed_transaction>();
// shared_ptr<packed_transaction> needed here because packed_transaction_ptr is shared_ptr<const packed_transaction>
std::shared_ptr<packed_transaction> ptr = std::make_shared<packed_transaction>();
fc::raw::unpack( ds, *ptr );
if( trx_in_progress_sz > def_max_trx_in_progress_size) {
char reason[72];
Expand Down

0 comments on commit 382f648

Please sign in to comment.