20 #ifndef included_api_types_h 21 #define included_api_types_h 24 #include <arpa/inet.h> 37 memcpy(str->
buf, buf, len);
39 return len +
sizeof (
u32);
52 return ntohl (astr->
length);
58 return strndup((
char *)astr->
buf, ntohl (astr->
length));
static char * vl_api_from_api_string_c(vl_api_string_t *astr)
Optimized string handling code, including c11-compliant "safe C library" variants.
static int vl_api_to_api_string(u32 len, const char *buf, vl_api_string_t *str)
static u32 vl_api_string_len(vl_api_string_t *astr)
static u8 * vl_api_from_api_string(vl_api_string_t *astr)