Deallocating memory used by UAVCAN virtual iface on destruction

This commit is contained in:
Pavel Kirienko 2015-10-16 23:17:07 +03:00 committed by Lorenz Meier
parent a570d1de7d
commit 1ace017cb8

View File

@ -114,6 +114,14 @@ public:
uavcan::IsDynamicallyAllocatable<Item>::check();
}
~Queue()
{
while (!isEmpty())
{
pop();
}
}
bool isEmpty() const { return list_.isEmpty(); }
/**