Skip to content

Commit

Permalink
fix(asan): heap-use-after-free caused by replica_test_base::create_te…
Browse files Browse the repository at this point in the history
…st_mutation (#733)
  • Loading branch information
levy5307 authored Jan 21, 2021
1 parent 2ddad7d commit 5c8de19
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/replica/test/replica_test_base.h
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ struct replica_test_base : replica_stub_test_base
mu->data.updates.emplace_back(mutation_update());
mu->data.updates.back().code =
RPC_COLD_BACKUP; // whatever code it is, but never be WRITE_EMPTY
mu->data.updates.back().data.assign(data.data(), 0, data.length());
mu->data.updates.back().data = blob::create_from_bytes(std::string(data));
mu->client_requests.push_back(nullptr);

// replica_duplicator always loads from hard disk,
Expand Down

0 comments on commit 5c8de19

Please sign in to comment.