Hi there,
When we call CoAP_CreateMessage(), we allocate some buffer for the message. After successfully allocating the buffer we check PayloadMaxSize and return null if exceeded. Should we free the buffer prior to returning or are we relying on the caller to clean up the buffer?
Hi there, When we call CoAP_CreateMessage(), we allocate some buffer for the message. After successfully allocating the buffer we check PayloadMaxSize and return null if exceeded. Should we free the buffer prior to returning or are we relying on the caller to clean up the buffer?
https://github.com/lobaro/lobaro-coap/blob/7f5fed4abf481cf7bef7e143fe4c8d2aee41abe8/src/coap_message.c#L165