@@ -240,6 +240,14 @@ typedef struct udpard_fragment_t
240240 udpard_mem_deleter_t payload_deleter ;
241241} udpard_fragment_t ;
242242
243+ /// Frees the memory allocated for the payload and its fragment headers using the correct memory resources.
244+ /// The application can do the same thing manually if it has access to the required context to compute the size,
245+ /// or if the memory resource implementation does not require deallocation size.
246+ /// The head of the fragment list is passed by value so it is not freed. This is in line with the udpard_rx_transfer_t
247+ /// design, where the head is stored by value to reduce indirection in small transfers. We call it Scott's Head.
248+ /// If any of the arguments are NULL, the function has no effect.
249+ void udpard_fragment_free (const udpard_fragment_t head , const udpard_mem_resource_t memory_fragment );
250+
243251// =====================================================================================================================
244252// ================================================= TX PIPELINE =================================================
245253// =====================================================================================================================
@@ -621,16 +629,6 @@ bool udpard_rx_new(udpard_rx_t* const self,
621629/// The time complexity is logarithmic in the number of living sessions.
622630void udpard_rx_poll (udpard_rx_t * const self , const udpard_microsecond_t now );
623631
624- /// Frees the memory allocated for the payload and its fragment headers using the correct memory resources.
625- /// The application can do the same thing manually if it has access to the required context to compute the size,
626- /// or if the memory resource implementation does not require deallocation size.
627- /// The head of the fragment list is passed by value so it is not freed. This is in line with the UdpardRxTransfer
628- /// design, where the head is stored by value to reduce indirection in small transfers. We call it Scott's Head.
629- /// If any of the arguments are NULL, the function has no effect.
630- void udpard_rx_fragment_free (const udpard_fragment_t head ,
631- const udpard_mem_resource_t memory_fragment ,
632- const udpard_mem_deleter_t memory_payload );
633-
634632/// To subscribe to a subject, the application should do this:
635633/// 1. Create a new udpard_rx_subscription_t instance using udpard_rx_subscription_new().
636634/// 2. Per redundant network interface:
0 commit comments