ForCES: Remove never used macros

This commit is contained in:
Francois-Xavier Le Bail 2018-01-08 16:09:24 +01:00
parent e8ff00c320
commit d32eeddb46

View File

@ -386,15 +386,11 @@ struct forces_tlv {
#define F_ALN_LEN(len) ( ((len)+ForCES_ALNL-1) & ~(ForCES_ALNL-1) ) #define F_ALN_LEN(len) ( ((len)+ForCES_ALNL-1) & ~(ForCES_ALNL-1) )
#define GET_TOP_TLV(fhdr) ((const struct forces_tlv *)((fhdr) + sizeof (struct forcesh))) #define GET_TOP_TLV(fhdr) ((const struct forces_tlv *)((fhdr) + sizeof (struct forcesh)))
#define TLV_SET_LEN(len) (F_ALN_LEN(TLV_HDRL) + (len)) #define TLV_SET_LEN(len) (F_ALN_LEN(TLV_HDRL) + (len))
#define TLV_ALN_LEN(len) F_ALN_LEN(TLV_SET_LEN(len))
#define TLV_RDAT_LEN(tlv) (EXTRACT_BE_U_2(&(tlv)->length) - TLV_SET_LEN(0)
#define TLV_DATA(tlvp) ((const void*)(((const char*)(tlvp)) + TLV_SET_LEN(0))) #define TLV_DATA(tlvp) ((const void*)(((const char*)(tlvp)) + TLV_SET_LEN(0)))
#define GO_NXT_TLV(tlv,rlen) ((rlen) -= F_ALN_LEN(EXTRACT_BE_U_2(&(tlv)->length)), \ #define GO_NXT_TLV(tlv,rlen) ((rlen) -= F_ALN_LEN(EXTRACT_BE_U_2(&(tlv)->length)), \
(const struct forces_tlv*)(((const char*)(tlv)) \ (const struct forces_tlv*)(((const char*)(tlv)) \
+ F_ALN_LEN(EXTRACT_BE_U_2(&(tlv)->length)))) + F_ALN_LEN(EXTRACT_BE_U_2(&(tlv)->length))))
#define ILV_SET_LEN(len) (F_ALN_LEN(ILV_HDRL) + (len)) #define ILV_SET_LEN(len) (F_ALN_LEN(ILV_HDRL) + (len))
#define ILV_ALN_LEN(len) F_ALN_LEN(ILV_SET_LEN(len))
#define ILV_RDAT_LEN(ilv) (EXTRACT_BE_U_4(&(ilv)->length)) - ILV_SET_LEN(0)
#define ILV_DATA(ilvp) ((const void*)(((const char*)(ilvp)) + ILV_SET_LEN(0))) #define ILV_DATA(ilvp) ((const void*)(((const char*)(ilvp)) + ILV_SET_LEN(0)))
#define GO_NXT_ILV(ilv,rlen) ((rlen) -= F_ALN_LEN(EXTRACT_BE_U_4(&(ilv)->length)), \ #define GO_NXT_ILV(ilv,rlen) ((rlen) -= F_ALN_LEN(EXTRACT_BE_U_4(&(ilv)->length)), \
(const struct forces_ilv *)(((const char*)(ilv)) \ (const struct forces_ilv *)(((const char*)(ilv)) \