diff --git a/src/capwap/lwapp.h b/src/capwap/lwapp.h index 99eccda4..14d72a37 100644 --- a/src/capwap/lwapp.h +++ b/src/capwap/lwapp.h @@ -143,6 +143,16 @@ (*((uint32_t*)(dst)) = htonl(dw),4) +#define lw_get_byte(src)\ + (*(uint8_t*)(src)) + +#define lw_get_word(src) \ + (ntohs( *(uint16_t*(src)))) + +#define lw_get_dword(src) \ + (ntohl( *(uint32_t*(src)))) + + /* the following functions are defined as static inline and not as macro to avoid any side effects */