9 #include "coap_config.h" 42 memcpy (s->
s, data, size);
Coap string data definition.
Coap string data definition with const data.
coap_string_t * coap_new_string(size_t size)
Returns a new string object with at least size+1 bytes storage allocated.
void coap_delete_string(coap_string_t *s)
Deletes the given string and releases any memory allocated.
void coap_delete_str_const(coap_str_const_t *s)
Deletes the given const string and releases any memory allocated.
struct coap_string_t coap_string_t
Coap string data definition.
size_t length
length of string
void * coap_malloc_type(coap_memory_tag_t type, size_t size)
Allocates a chunk of size bytes and returns a pointer to the newly allocated memory.
#define coap_log(level,...)
Logging function.
coap_str_const_t * coap_new_str_const(const uint8_t *data, size_t size)
Returns a new const string object with at least size+1 bytes storage allocated, and the provided data...
void coap_free_type(coap_memory_tag_t type, void *p)
Releases the memory that was allocated by coap_malloc_type().