mirror of
https://github.com/FairRootGroup/FairMQ.git
synced 2025-10-15 09:31:45 +00:00
Equip FairMQMessage with pointer to factory (at creation)
the patch seems big but most of it is just propagating the new notion of constness of the factory - since it keeps track of created messages with the internal allocator it no longer is const
This commit is contained in:
@@ -43,7 +43,7 @@ class PollIn : public FairMQDevice
|
||||
|
||||
auto Run() -> void override
|
||||
{
|
||||
vector<const FairMQChannel*> chans;
|
||||
vector<FairMQChannel*> chans;
|
||||
|
||||
chans.push_back(&fChannels.at("data1").at(0));
|
||||
chans.push_back(&fChannels.at("data2").at(0));
|
||||
|
@@ -166,7 +166,7 @@ TEST(MemoryResources, adoptVector_test)
|
||||
std::memcpy(message->GetData(), tmpBuf, 3 * sizeof(testData));
|
||||
|
||||
auto adoptedOwner =
|
||||
adoptVector<testData>(3, factoryZMQ->GetMemoryResource(), std::move(message));
|
||||
adoptVector<testData>(3, std::move(message));
|
||||
EXPECT_TRUE(adoptedOwner[0].i == 3);
|
||||
EXPECT_TRUE(adoptedOwner[1].i == 2);
|
||||
EXPECT_TRUE(adoptedOwner[2].i == 1);
|
||||
|
Reference in New Issue
Block a user