Dynamic memory refactoring: Entire library now uses IPoolAllocator instead of IAllocator, which was removed completely. This change was needed to enable TX queue constraints, see the next commits.

This commit is contained in:
Pavel Kirienko
2014-04-12 17:17:06 +04:00
parent 5808bfc0c9
commit 4e7287358a
14 changed files with 120 additions and 61 deletions
@@ -122,7 +122,7 @@ class UAVCAN_EXPORT GenericSubscriber : public GenericSubscriberBase
}
public:
TransferForwarder(SelfType& obj, const DataTypeDescriptor& data_type, IAllocator& allocator)
TransferForwarder(SelfType& obj, const DataTypeDescriptor& data_type, IPoolAllocator& allocator)
: TransferListenerType(obj.node_.getDispatcher().getTransferPerfCounter(), data_type, allocator)
, obj_(obj)
{ }
@@ -198,7 +198,7 @@ int GenericSubscriber<DataSpec, DataStruct, TransferListenerType>::checkInit()
UAVCAN_TRACE("GenericSubscriber", "Type [%s] is not registered", DataSpec::getDataTypeFullName());
return -ErrUnknownDataType;
}
forwarder_.template construct<SelfType&, const DataTypeDescriptor&, IAllocator&>
forwarder_.template construct<SelfType&, const DataTypeDescriptor&, IPoolAllocator&>
(*this, *descr, node_.getAllocator());
return 0;
}